Agent Stack is an open platform to help you discover, run, and compose AI agents from any framework. This tutorial demonstrates how to consume agents from the Agent Stack and expose agents built in BeeAI Framework to the Agent Stack. PrerequisitesDocumentation Index
Fetch the complete documentation index at: https://framework.beeai.dev/llms.txt
Use this file to discover all available pages before exploring further.
- Agent Stack installed and running locally
- BeeAI Framework installed with
pip install beeai-framework[agentstack]
Consuming from the platform (client)
TheAgentStackAgent class allows you to connect to any agent hosted on the Agent Stack. This means that you can interact with agents built from any framework!
Use AgentStackAgent when:
- You’re connecting specifically to the Agent Stack services.
- You want forward compatibility for the Agent Stack, no matter which protocol it is based on.
chat agent:
GPT Researcher agent researches a topic, and the Podcast creator takes the research report and produces a podcast transcript.
You can adjust or expand this pattern to orchestrate more complex multi-agent workflows.
Python
Python
Python
Exposing to the platform (server)
TheAgentStackServer class exposes an agent or any other runnable (tool/chat model, …) to the Agent Stack.
It gets automatically registered to the platform and allows you to access and use the agents directly in the platform.
Key Features:
- easy to expose (deploy) the current application to the production-ready environment
- built-in trajectory, forms integration, LLM inference support, …
- easy to extend and debug
Agent Stack supports only one entry per server. To register more, you need to spawn more servers.
Configuration
Server The server’s behavior can be influenced via attributes listed inAgentStackServerConfig class (host, port, self registration, …).
Internally the server preserves every conversation, the custom strategy can be used by implementing the base MemoryManager class.
Python
agent.meta property).
However, this information can be overridden during agent registration. See the following example.
Python
Customization
The Agent Stack has a concept of extensions that enable access to external services and UI components via dependency injection. The framework internally uses the following extensions:- Form Extension: for displaying prompts and other checks (for instance when using
AskPermissionRequirement).. - Trajectory Extension: for showing agent’s intermediate steps throughout the execution
The current entries are listed in the
BaseAgentStackExtensions class.PlatformCitationMiddleware class.
Learn more about the Middleware concept.