UpstashRedisByteStore
features and configurations head to the API reference.
Overview
TheUpstashRedisStore
is an implementation of ByteStore
that stores everything in your Upstash-hosted Redis instance.
To use the base RedisStore
instead, see this guide.
Integration details
Class | Package | Local | JS support | Downloads | Version |
---|---|---|---|---|---|
UpstashRedisByteStore | langchain-community | ❌ | ✅ |
Setup
You’ll first need to sign up for an Upstash account. Next, you’ll need to create a Redis database to connect to.Credentials
Once you’ve created your database, get your database URL (don’t forget thehttps://
!) and token:
Installation
The LangChain Upstash integration lives in thelangchain-community
package. You’ll also need to install the upstash-redis
package as a peer dependency:
Instantiation
Now we can instantiate our byte store:Usage
You can set data under keys like this using themset
method:
mdelete
method:
API reference
For detailed documentation of allUpstashRedisByteStore
features and configurations, head to the API reference: python.langchain.com/api_reference/community/storage/langchain_community.storage.upstash_redis.UpstashRedisByteStore.html