## 2 Foundational Concepts and Technologies
### Multi-Agent Systems
#### 2.3.2 Integration with LLMs  
LLMs serve as the cognitive foundation of modern AI agents, functioning effectively as their \"brain\" and enabling advanced reasoning, planning, and decision-making capabilities [6; 8]. This integration transforms traditional agents into more versatile and intelligent systems capable of handling complex tasks through natural language understanding and generation. The architecture of an LLM-based agent comprises several key components that work in concert to create an intelligent system. At its core, the LLM functions as the central processing unit [33; 37], interpreting inputs, generating responses, and coordinating various agent functions through natural language. This integration allows agents to leverage the extensive knowledge and reasoning capabilities embedded within the LLM while maintaining structured interaction with their environment. As presented on Figure 9, agent cognitive architecture is built around four fundamental components:  
* Planning: The planning component harnesses the LLM's reasoning capabilities to devise action sequences based on objectives and environmental constraints [32]. This module employs various techniques such as Chain-of-Thought (CoT) and Tree-of-Thought (ToT) prompting, enabling the agent to break down complex tasks into manageable steps. The LLM's natural language processing abilities allow it to understand goals, generate plans, and adapt strategies based on changing circumstances. * Memory: The memory architecture consists of two primary components: short-term memory for immediate context and task-related information and long-term memory for storing substantial volumes of knowledge and past experiences [37]. The LLM interacts with both memory types to maintain context awareness and improve decision-making over time. This dual-memory system enables the agent to learn from past interactions while remaining responsive to current situations. * Tools: LLM-based agents are equipped with various specialized tools that extend their capabilities beyond pure language processing [8]. The tools component presents specific instruments that were created for our system to adjust it for analysis of financial markets:  
Figure 9: Overview of a LLM autonomous agent, adapted from Ref. [37]. Stock market data: provides access to real-time and historical market information, essential for informed decision-making. * Elliott wave reader: tool for technical analysis, helping the agent identify and interpret Elliott wave patterns in price movements. * Chart generator: allows the agent to visualize market data, especially Elliott waves, creating graphical representations of detected waves. This tool is directly connected to Elliott waves reader tool. * Database connector: enables the agent to access and manage structured data of backtesting results. * Context: The context management system enables the agent to maintain and update its understanding of the current situation. The LLM processes incoming information and integrates it with existing knowledge [39], allowing the agent to adapt its responses and decisions based on evolving circumstances. This component ensures that the agent's analyses and recommendations remain relevant and well-grounded in current conditions. The integration between these components is facilitated by the LLM's natural language capabilities. For example, when an agent needs to analyze market trends, the LLM can interpret complex market data provided by the tools, apply relevant analytical frameworks stored in memory, and generate coherent analysis and recommendations [7; 37]. The LLM's ability to process and generate natural language makes it an ideal interface between the agent's various components and external stakeholders. This architecture enables LLM-based agents to perform sophisticated tasks that were previously challenging for traditional agents.