A heterogeneous multi-agent system for adaptive web applications