microsoft / microsoft/agent-framework

Python: [Feature]: Add Valkey Context Provider and Chat Message Store

Open
#5,260 4 comments 0 reactions 2 assignees View on GitHub

@westey-m is already working on this.

Since Jun 4, 2026.

agents python
Dominant language
Python
Stars
13.6k
Forks
2.3k
Avg merge
2d 45m
Merged PRs (30d)
358

Description

### Description

### Problem
The current `agent-framework-redis` package depends on `redisvl>=0.8.2`, which requires Redis Stack's RediSearch module for the `RedisContextProvider`'s vector operations. While Redis and Valkey are mostly protocol-compatible for core features, their search modules are not compatible — code that requires RediSearch will not work with Valkey's valkey-search module. Additionally, the RedisVL library itself has known incompatibilities with Valkey. Since this dependency is bundled at the package level, even the `RedisChatMessageStore` (which only needs basic key-value operations) pulls in RedisVL.

This is a practical blocker for teams running Valkey in production — whether self-hosted or through managed cloud services — which has become increasingly common since the Redis license change.

### Proposed Solution

Add a new `agent-framework-valkey` package providing:

1. **`ValkeyChatMessageStore`** — persistent chat message storage implementing `ChatMessageStoreProtocol`, using `valkey-glide` (the official Valkey Python client) for basic key-value operations.

2. **`ValkeyContextProvider`** — long-term memory context provider implementing the `ContextProvider` protocol, using `valkey-glide` with Valkey's native vector search capabilities for semantic retrieval of past conversation context.

The package would follow the same structure and patterns as `agent-framework-redis` and `agent-framework-mem0`.

#### Value

- Performance: Valkey's valkey-search module delivers single-digit millisecond latency with 99%+ recall for vector search operations
- Scaling: Linear scaling with cluster mode support
- Open-source governance: Linux Foundation project with community-driven development, clear licensing
- Cloud support: Managed services from major cloud providers.
- Migration path: Easy migration from Redis deployments for teams affected by the Redis license change

### Code Sample

```markdown

```

### Language/SDK

Python

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.