How an AI Agent Works - A Full Dissection - Simplified