-
Notifications
You must be signed in to change notification settings - Fork 779
Updated Dapr Agents docs to align with recent quickstart changes #4987
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: v1.16
Are you sure you want to change the base?
Conversation
Signed-off-by: Bilgin Ibryam <bibryam@gmail.com>
msfussell
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs another pass to make it consistent with component naming defaults
| # Configure the agent to use Dapr State Store for conversation history. | ||
| memory=AgentMemoryConfig( | ||
| store=ConversationDaprStateMemory( | ||
| store_name="conversation-statestore", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All the names here should match those that we agree as the default names. Should this not be "agent-memory" ?
| * `06_durable_agent_http.py` – the main durable weather agent application exposed over HTTP | ||
| * `function_tools.py` – contains `slow_weather_func`, the tool used by the agent | ||
| * `resources/llm-provider.yaml` – Conversation API and LLM configuration | ||
| * `resources/conversation-statestore.yaml` – conversation memory state store |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be called conversation or just memory store? And where does the term session come into this?
| ) | ||
| ), | ||
| # This is where the execution state is stored | ||
| state=AgentStateConfig( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I actually think this class should be renamed to AgentWorkflowConfig() and not AgentStateConfig() so it is explicit
| ), | ||
| ``` | ||
|
|
||
| This tells the agent to store conversation history in a Dapr state store named `conversation-statestore`, under a given `session_id`. The matching Dapr component is `resources/conversation-statestore.yaml`: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comment above about renaming this to memory-statestore
| kind: Component | ||
| metadata: | ||
| name: openai | ||
| name: conversation-statestore |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should use the same as the default names here IMO. So agent-memory
| def get_weather() -> str: | ||
| """Get current weather.""" | ||
| return "It's 72°F and sunny" | ||
| * This is again a Redis-backed store holds durable workflow state. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| * This is again a Redis-backed store holds durable workflow state. | |
| * This is another Redis state store that holds the durable workflow state. |
|
|
||
|
|
||
| Dapr Agents is a developer framework for building durable and resilient AI agent systems powered by Large Language Models (LLMs). Built on the battle-tested Dapr project, it enables developers to create autonomous systems that reason through problems, make dynamic decisions, and collaborate seamlessly. It includes built-in observability and stateful workflow execution to ensure agentic workflows complete successfully, regardless of complexity. Whether you're developing single-agent applications or complex multi-agent workflows, Dapr Agents provides the infrastructure for intelligent, adaptive systems that scale across environments. | ||
| Dapr Agents is a developer framework for building durable and resilient AI agent systems powered by Large Language Models (LLMs). Built on the battle-tested Dapr project, it enables developers to create autonomous systems that have identity, reason through problems, make dynamic decisions, and collaborate seamlessly. It includes built-in observability and stateful workflow execution to ensure agentic workflows complete successfully, regardless of complexity. Whether you're developing single-agent applications or complex multi-agent workflows, Dapr Agents provides the infrastructure for intellI want to organise only the section below. igent, adaptive systems that scale across environments. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks to be a grammar mistake here
"for intellI want to organise only the section below. igent, adaptive "
| | [**MCP Support**]({{% ref "dapr-agents-core-concepts.md#mcp-support" %}}) | Built-in support for [Model Context Protocol](https://modelcontextprotocol.io/) enabling agents to dynamically discover and invoke external tools through standardized interfaces. | ||
| | [**Memory Management**]({{% ref "dapr-agents-core-concepts.md#memory" %}}) | Retain context across interactions with options from simple in-memory lists to vector databases, integrating with [Dapr state stores]({{% ref state-management-overview.md %}}) for scalable, persistent memory. | ||
| | [**Durable Agents**]({{% ref "dapr-agents-core-concepts.md#durable-agents" %}}) | Workflow-backed agents that provide fault-tolerant execution with persistent state management and automatic retry mechanisms for long-running processes. | ||
| | [**Agent Runner**]({{% ref "dapr-agents-core-concepts.md#agent-runner" %}}) | Expose agents over HTTP or subscribe to a PubSub for long-running tasks, enabling API access to agents without requiring a user interface or human intervention. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I could not find a good example of what the Agent Runner does? Must it be 1:1 to an agent, or can it have many agents associated with it? I think you have to have much more than this in the docs.
| ), | ||
| ) | ||
|
|
||
| # This runner will run the agent and expose it on port 8001 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would love to have a longer more detailed description of what a runner can do here. in particular is this 1:1 to an agent?
| ), | ||
| ) | ||
|
|
||
| # This runner will run the agent and expose it on port 8001 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| # This runner will run the agent and expose it on port 8001 | |
| # The AgentRunner expose the weather agent on HTTP port 8001 using the serve capability. You could also expose the weather agent as standalone or to send message with XXX" <- Complete this |
Thank you for helping make the Dapr documentation better!
Please follow this checklist before submitting:
In addition, please fill out the following to help reviewers understand this pull request:
Description
06_durable_agent_http.pyas the primary walkthrough. Updated the flow to cover cloning the repo, environment setup, durable agent creation, Dapr component configuration, HTTP execution viaAgentRunner, durability behavior, and inspection with Diagrid Dashboard.Issue reference