Skip to main content

llama-index storage-chat-store postgres integration

Project description

LlamaIndex Chat_Store Integration: Postgres Chat Store

Installation

pip install llama-index-storage-chat-store-postgres

Usage

Using PostgresChatStore, you can store your chat history remotely, without having to worry about manually persisting and loading the chat history.

from llama_index.storage.chat_store.postgres import PostgresChatStore
from llama_index.core.memory import ChatMemoryBuffer

chat_store = PostgresChatStore.from_uri(
    uri="postgresql+asyncpg://postgres:password@127.0.0.1:5432/database",
)

chat_memory = ChatMemoryBuffer.from_defaults(
    token_limit=3000,
    chat_store=chat_store,
    chat_store_key="user1",
)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file llama_index_storage_chat_store_postgres-0.3.0.tar.gz.

File metadata

File hashes

Hashes for llama_index_storage_chat_store_postgres-0.3.0.tar.gz
Algorithm Hash digest
SHA256 a818e881f9e048eb4f639a4526cfd0e646c53d3de8ef8ca9767d2aff64c76d92
MD5 43e15b21f6621428e3e16dcae1102a22
BLAKE2b-256 99e0f2d3f74a3465e2b492817df2e6ec4873bdc579f547245135f1b53603c5f1

See more details on using hashes here.

File details

Details for the file llama_index_storage_chat_store_postgres-0.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for llama_index_storage_chat_store_postgres-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2cdd70adb915c7111849058df090aa71650e0c0eeda41fca8666ebeb4d85285d
MD5 eac7e0d42f537dc96bee1d561aa8ca3a
BLAKE2b-256 eb43ace3d73b55be6e0bd325c075851f91c721db29e59338b61057e547565d60

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page