Configuration
July 6, 2026 · View on GitHub
This package ships Redis Agent Memory surfaces and direct Redis plugins for the NeMo Agent Toolkit.
Redis Agent Memory is a production-ready agent memory layer that extracts and stores relevant information and learns over time.
Direct Redis memory provides a more standard semantic memory layer for LLM applications.
Full Redis Agent Memory auto wrapper
- Long-term memory backend:
_type: redis_agent_memory_backend - Native automatic wrapper:
_type: redis_agent_memory_auto_memory
Direct Redis (nat.plugins entry point nat_redis → nat.plugins.redis.register)
- In-Redis vector memory:
_type: redis_memory - Object store:
_type: redis
For Python code, use nat.plugins.redis.* — the same module layout as NeMo
Agent Toolkit’s in-tree package.
Long-Term Memory Backend
Use _type: redis_agent_memory_backend when you want Redis Agent Memory behind NAT's
standard MemoryEditor contract.
memory:
redis_memory:
_type: redis_agent_memory_backend
base_url: http://localhost:8000
default_namespace: nat
timeout: 30.0
default_model_name: null
default_context_window_max: null
Supported config fields:
base_urldefault_namespacetimeoutdefault_model_namedefault_context_window_max- NAT retry settings from
RetryMixin
Runtime behavior:
add_items()creates long-term memories with optional Agent Memory fields such assession_id,namespace,entities,event_date, andmemory_typeadd_items()falls back to NATconversation_idforsession_idwhen no explicit value is providedsearch()requiresuser_idand forwards Agent Memory filters such assession_id,namespace,topics,entities,memory_type,distance_threshold, andrecencysearch()falls back to NATuser_idwhen the current runtime context provides oneremove_items()supports direct deletion bymemory_id/memory_idsor filtered deletion by search
Native Wrapper
Use _type: redis_agent_memory_auto_memory when you want Redis Agent
Memory to manage working memory plus memory_prompt hydration on every turn.
memory:
redis_memory:
_type: redis_agent_memory_backend
base_url: http://localhost:8000
default_namespace: nat
functions:
assistant_chat:
_type: chat_completion
llm_name: openai_llm
workflow:
_type: redis_agent_memory_auto_memory
inner_agent_name: assistant_chat
memory_name: redis_memory
default_user_id: default_user
default_session_id: default_session
memory_prompt:
optimize_query: false
long_term_search:
limit: 5
working_memory:
namespace: nat
model_name: gpt-4o-mini
context_window_max: null
ttl_seconds: 86400
long_term_memory_strategy:
strategy: discrete
Wrapper fields:
inner_agent_name: NAT function that receives the hydratedChatRequestmemory_name: name of an_type: redis_agent_memory_backendmemory configdefault_user_id: fallback when NAT runtime context has nouser_iddefault_session_id: fallback when NAT runtime context has noconversation_idmemory_prompt.optimize_querymemory_prompt.long_term_search.limitmemory_prompt.long_term_search.offsetmemory_prompt.long_term_search.namespacememory_prompt.long_term_search.topicsmemory_prompt.long_term_search.entitiesmemory_prompt.long_term_search.memory_typememory_prompt.long_term_search.distance_thresholdmemory_prompt.long_term_search.recency.*working_memory.namespaceworking_memory.model_nameworking_memory.context_window_maxworking_memory.ttl_secondsworking_memory.long_term_memory_strategy.strategyworking_memory.long_term_memory_strategy.config
Runtime identity mapping:
- NAT
user_id-> Redis Agent Memoryuser_id - NAT
conversation_id-> Redis Agent Memorysession_id default_user_idanddefault_session_idare only fallbacks
Wrapper constraints:
memory_namemust point to an_type: redis_agent_memory_backendmemory configinner_agent_namemust acceptChatRequestorChatRequestOrMessage- the wrapper stores the completed user/assistant turn back into working memory after the inner agent responds
Wrapper flow:
- Resolve NAT
user_idandconversation_id. - Create or load Redis Agent Memory working memory for that identity.
- Call
memory_prompt(...), invoke the inner chat function with the hydrated request, and append the finished turn back into working memory.
Direct Redis memory (redis_memory)
Use _type: redis_memory for the lightweight Redis-backed MemoryEditor that
stores JSON documents and uses RediSearch vector queries.
Requirements:
- Redis with JSON and search (for example Redis Stack), because the implementation creates a JSON index and runs vector KNN queries.
- A workflow embedder instance;
embeddermust reference its name in the workflow configuration.
memory:
redis_ltm:
_type: redis_memory
host: localhost
port: 6379
db: 0
key_prefix: nat
embedder: my_openai_embedder
Supported config fields:
host,port,db,password(optional secret),key_prefixembedder:EmbedderRefto a configured embedder (LangChain wrapper)
Direct Redis object store (redis)
Use _type: redis for the NAT object store that persists ObjectStoreItem
JSON at keys under nat/object_store/{bucket_name}/..., with optional TTL.
object_store:
artifacts:
_type: redis
host: localhost
port: 6379
db: 0
bucket_name: my_bucket
ttl: 3600