How theagenticai/cortexon works
Your C4 Levels
• Context Level: Show CortexON as the primary system surrounded by its external actors and integrations. Include external systems like Google Custom Search, Anthropic, Browserbase, LogFire, and Vault.
• Container Level: Break down CortexON into its major software containers. Based on the file tree and README, identify these containers:
– Backend Engines (found mainly under the “cortex_on” directory) that include core agents (e.g., Web Agent, Code Agent, Planner/Orchestrator, etc.)
– Frontend Application (in the “frontend” directory) built in React/TypeScript.
– TA-Browser Module: A distinct container that handles specialized browser automation tasks (under “ta-browser”).
– Supporting Services (e.g., the Docker Compose configuration which defines how containers interact).
• Component Level: Delve into each container to show the internal components/modules.
– For the “cortex_on” container, illustrate different agents (code_agent, orchestrator_agent, planner_agent, file/web agents) and utilities (executors, markdown browser, etc.) as sub-components. Indicate inter-agent communication.
– For the frontend container, present components like Home (chat interface, code block, terminal block interfaces), Vault UI components, and service integrations that call backend APIs.
– For the ta-browser container, show its core modules responsible for browser-based automation (e.g., browser_agent, critique_agent, explainer_agent, etc.) and its internal server structure.
Relationships and Interactions
– From the Frontend container to the Backend container: indicate web requests and API interactions (e.g., FastAPI backend APIs).
– From the Backend’s central orchestrator to individual agents (code, web, planner) highlighting multi-agent collaboration.
– Between the TA-Browser container and the Backend, since they complement each other for browser automation tasks.
Architectural Patterns and Technologies
• Microservices/multi-container approach as orchestrated via Docker Compose.
• That the design is modular with clearly demarcated responsibilities among agents.
• Mention technologies: FastAPI for backend, React/TypeScript and TailwindCSS for frontend, Docker for containerization, and various external APIs/integrations.
• The use of a multi-agent system pattern should be clearly highlighted — each specialized agent is a “component” with defined tasks and interactions.