Agno supports using DynamoDB as a database with the DynamoDb class.

Usage

To connect to DynamoDB, you will need valid AWS credentials. You can set them as environment variables:
  • AWS_REGION: The AWS region to connect to.
  • AWS_ACCESS_KEY_ID: Your AWS access key id.
  • AWS_SECRET_ACCESS_KEY: Your AWS secret access key.
dynamo_for_agent.py
from agno.db.dynamo import DynamoDb

# Setup your Database
db = DynamoDb()

# Setup your Agent with the Database
agent = Agent(db=db)

Params

ParameterTypeDefaultDescription
db_clientNone-The DynamoDB client to use.
region_nameoptional[str]-AWS region name.
aws_access_key_idoptional[str]-AWS access key ID.
aws_secret_access_keyoptional[str]-AWS secret access key.
session_tableoptional[str]-The name of the session table.
memory_tableoptional[str]-The name of the memory table.
metrics_tableoptional[str]-The name of the metrics table.
eval_tableoptional[str]-The name of the eval table.
knowledge_tableoptional[str]-The name of the knowledge table.

Developer Resources