rag-chat  by upstash

Accelerate RAG chat prototyping

Created 1 year ago
252 stars

Top 99.6% on SourcePulse

GitHubView on GitHub
1 Expert Loves This Project
Project Summary

This project provides a prototype SDK for accelerating the development of retrieval-augmented generation (RAG) chat applications. It targets developers seeking a streamlined approach to RAG prototyping, offering minimal setup and configuration. However, the Upstash Team explicitly recommends established SDKs like Vercel AI SDK, Langchain, and LlamaIndex for production-ready applications.

How It Works

The @upstash/rag-chat package simplifies RAG implementation by offering Next.js compatibility with streaming capabilities. It supports out-of-the-box ingestion of various data sources, including websites and PDFs, and features an optional built-in vector store for managing knowledge bases. Additional optional components include Redis compatibility for efficient chat history management, rate limiting, and integrations with analytics platforms like Helicone, Langsmith, and Cloudflare AI Gateway.

Quick Start & Requirements

Installation is straightforward via package managers: npm i @upstash/rag-chat, pnpm add @upstash/rag-chat, or bun add @upstash/rag-chat. Environment variables are required for service URLs and API keys, including UPSTASH_VECTOR_REST_URL, UPSTASH_VECTOR_REST_TOKEN, and either OPENAI_API_KEY or QSTASH_TOKEN. Optional Redis support requires UPSTASH_REDIS_REST_URL and UPSTASH_REDIS_REST_TOKEN. Basic usage involves initializing RAGChat and calling its chat method, with context added via text or file sources.

Highlighted Details

  • Next.js compatibility with streaming support.
  • Out-of-the-box ingestion for websites and PDFs.
  • Optional integrated vector store for knowledge bases.
  • Optional Redis integration for chat history persistence.
  • Analytics integrations with Helicone, Langsmith, and Cloudflare AI Gateway.

Maintenance & Community

This project is designated as a Community Project, meaning it is maintained and supported by the community. Upstash may contribute but does not offer official support or assume responsibility for its development or stability.

Licensing & Compatibility

The specific open-source license is not detailed in the provided README content.

Limitations & Caveats

The SDK is explicitly labeled as a prototype, and the maintainers advise against its use in production environments, recommending alternatives like Vercel AI SDK, Langchain, or LlamaIndex. As a community project, it lacks official support from Upstash, which may impact long-term maintenance and reliability.

Health Check
Last Commit

9 months ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
1 stars in the last 30 days

Explore Similar Projects

Starred by Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems"), Ishaan Jaffer Ishaan Jaffer(Cofounder of LiteLLM), and
4 more.

chathub by chathub-dev

0.1%
10k
All-in-one chatbot client
Created 2 years ago
Updated 7 months ago
Feedback? Help us improve.