Skip to content

[feat] Add Valkey database and Vector database adapters#7794

Closed
edlng wants to merge 3 commits into
agno-agi:mainfrom
edlng:feat/valkey
Closed

[feat] Add Valkey database and Vector database adapters#7794
edlng wants to merge 3 commits into
agno-agi:mainfrom
edlng:feat/valkey

Conversation

@edlng

@edlng edlng commented May 4, 2026

Copy link
Copy Markdown
Contributor

Summary

Closes #7795

Adds Valkey as a database backend (session store) and vector database adapter, using the Valkey GLIDE client (valkey-glide). Valkey is a Redis fork maintained by the Linux Foundation.

The session store (ValkeyDb) implements the BaseDb interface: sessions, memories, metrics, evals, knowledge, cultural knowledge, traces, spans, and learnings. Data is stored as JSON in Valkey keys with secondary index sets for filtered lookups.

The vector store (ValkeyDB) supports vector similarity search, keyword search, and document CRUD using Valkey's search module (for FT.SEARCH). Supports auth, TLS, and database selection.

Includes cookbook examples for storage and vector DB usage, unit tests with a mocked GLIDE client, integration tests against a live Valkey instance, and schema definitions that document the expected fields for each record type.

Type of change

  • Bug fix
  • New feature
  • Breaking change
  • Improvement
  • Model update
  • Other:

Checklist

  • Code complies with style guidelines
  • Ran format/validation scripts (./scripts/format.sh and ./scripts/validate.sh)
  • Self-review completed
  • Documentation updated (comments, docstrings)
  • Examples and guides: Relevant cookbook examples have been included or updated (if applicable)
  • Tested in clean environment
  • Tests added/updated (if applicable)

Duplicate and AI-Generated PR Check

  • I have searched existing open pull requests and confirmed that no other PR already addresses this issue
  • If a similar PR exists, I have explained below why this PR is a better approach
  • Check if this PR was entirely AI-generated (by Copilot, Claude Code, Cursor, etc.)

Additional notes

Known limitations, both consistent left as-is to remain consistent with the existing Redis adapter:

  • _find_keys_by_tag caps results at 1000 documents. Documented in the docstring.
  • keyword_search does not escape FT.SEARCH special characters. Documented in the docstring. Fixing this properly means changing both Redis and Valkey together, better as a separate PR.

Signed-off-by: Edward Liang <edward.liang@improving.com>
@edlng edlng requested a review from a team as a code owner May 4, 2026 18:28
@github-actions

github-actions Bot commented May 4, 2026

Copy link
Copy Markdown
Contributor

PR Triage

Missing issue link: Please link the issue this PR addresses using fixes #<issue_number>, closes #<issue_number>, or resolves #<issue_number> in the PR description. If there is no existing issue, please create one first.

@github-actions

Copy link
Copy Markdown
Contributor

This pull request has been automatically marked as stale due to 14 days of inactivity. If this is still relevant, please update it or leave a comment.

@github-actions github-actions Bot added the stale label May 19, 2026
@edlng

edlng commented May 19, 2026

Copy link
Copy Markdown
Contributor Author

Unmarking as stale.

@github-actions github-actions Bot removed the stale label May 20, 2026
@edlng

edlng commented May 20, 2026

Copy link
Copy Markdown
Contributor Author

Hey @kausmeows , could you take a quick look at this PR?

Signed-off-by: Edward Liang <edward.liang@improving.com>
@edlng

edlng commented Jun 8, 2026

Copy link
Copy Markdown
Contributor Author

Hey @kausmeows , could you take a quick look at this PR?

@harshsinha03

Copy link
Copy Markdown
Contributor

Hey @edlng closing this in favor of #8141. It'll go out in the next release. Thanks for using Agno!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] Add Valkey as a database and vector database option

2 participants