DoDo - A stateful agentic framework
Project description
dodo
A stateful agentic framework for building AI agents.
Installation
pip install dodoai
pip install dodoai[gemini] # With Gemini support
Quick Start
from dodo import Agent, Gemini
agent = Agent(llm=Gemini(), tools=[...], observe=my_observe_fn)
await agent.do("perform some task")
value = await agent.tell("some information")
ok = await agent.check("some condition is true")
Features
Three simple methods
await agent.do("fill out the form and submit") # Do a task
username = await agent.tell("the logged in user") # Get information
ok = await agent.check("user is logged in") # Check a condition
Stateful agents
# Agent remembers context across tasks
await agent.do("go to amazon.com")
await agent.do("search for laptop")
await agent.do("add first result to cart")
Structured output
class ProductInfo(BaseModel):
name: str
price: float
product = await agent.tell("product information", schema=ProductInfo)
Verdicts with reasons
ok = await agent.check("cart has 3 items")
if ok:
print("Success!")
else:
print(f"Failed: {ok.reason}")
Observation function
async def observe():
"""Return current environment state."""
return [Text(text="Current page: checkout")]
agent = Agent(llm=llm, tools=tools, observe=observe)
Error handling
try:
await agent.do("complete checkout")
except TaskAbortedError as e:
print(f"Task failed: {e}")
Supported LLMs
from dodo import Gemini
Gemini(model="gemini-2.5-flash") # Default
Gemini(model="gemini-2.5-pro") # Pro model
Creating Tools
from dodo import Tool, ToolResult, ToolResultStatus
from pydantic import BaseModel, Field
class SearchTool(Tool):
name = "search"
description = "Search for information"
class Params(BaseModel):
query: str = Field(description="Search query")
async def execute(self, params):
results = do_search(params.query)
return ToolResult(
name=self.name,
status=ToolResultStatus.SUCCESS,
description=f"Found {len(results)} results",
)
License
MIT
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file dodoai-0.1.0.tar.gz.
File metadata
- Download URL: dodoai-0.1.0.tar.gz
- Upload date:
- Size: 18.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3bce88140783752703813bb2de791254f31b2c8e55b147154a58524b403d72bf
|
|
| MD5 |
8210e2c1bad4c85890ca3ec4c9da64ef
|
|
| BLAKE2b-256 |
37e20141be44f67f293c7d96d03344e72c97528fbd12d7275ca6f089b34332d3
|
Provenance
The following attestation bundles were made for dodoai-0.1.0.tar.gz:
Publisher:
publish.yml on steve-z-wang/dodo
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
dodoai-0.1.0.tar.gz -
Subject digest:
3bce88140783752703813bb2de791254f31b2c8e55b147154a58524b403d72bf - Sigstore transparency entry: 719436174
- Sigstore integration time:
-
Permalink:
steve-z-wang/dodo@43c67c3644977d4fe28d8d62f9384933469f643a -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/steve-z-wang
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@43c67c3644977d4fe28d8d62f9384933469f643a -
Trigger Event:
release
-
Statement type:
File details
Details for the file dodoai-0.1.0-py3-none-any.whl.
File metadata
- Download URL: dodoai-0.1.0-py3-none-any.whl
- Upload date:
- Size: 23.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ba3520c032606ec59412545f6886357d6be62a51e9f683de0c6bb3768a814ec2
|
|
| MD5 |
1a08d19370c26d76b151f511fc1c2043
|
|
| BLAKE2b-256 |
234688edbb1ca4b736abc2911775ab99e3c4322d591341fbf00373983010ada2
|
Provenance
The following attestation bundles were made for dodoai-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on steve-z-wang/dodo
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
dodoai-0.1.0-py3-none-any.whl -
Subject digest:
ba3520c032606ec59412545f6886357d6be62a51e9f683de0c6bb3768a814ec2 - Sigstore transparency entry: 719436178
- Sigstore integration time:
-
Permalink:
steve-z-wang/dodo@43c67c3644977d4fe28d8d62f9384933469f643a -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/steve-z-wang
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@43c67c3644977d4fe28d8d62f9384933469f643a -
Trigger Event:
release
-
Statement type: