RAG Knowledge Base
AI-first · React + Node (Express) · 19 @molecule/* packages
Upload documents, semantic search, and AI-powered Q&A — with built-in Stripe-backed subscription tiers
Try it
Opens instantly. Runs on sample data, so changes reset on reload.
What is inside
Screens (17)
- Landing
/ - Login
/login - Signup
/signup - ForgotPassword
/forgot-password - ResetPassword
/reset-password - Ask
/ask(signed in) - Documents
/documents(signed in) - DocumentDetail
/documents/:id(signed in) - Sources
/sources(signed in) - Analytics
/analytics(signed in) - Settings
/settings(signed in) - SourceDetail
/sources/:id(signed in) - History
/history(signed in) - KnowledgeGraph
/graph(signed in) - Members
/members(signed in) - Notifications
/notifications(signed in) - Billing
/billing(signed in)
Data model (12 tables)
- collections — id, user_id, name, description, document_count, created_at, updatedAt
- sources — id, user_id, collection_id, kind, label, config_json, credentials_encrypted, last_sync_at, …
- documents — id, user_id, collection_id, source_id, title, slug, body_md, source_url, …
- qa_conversations — id, user_id, collection_id, title, started_at, last_message_at, created_at, updatedAt
- qa_entries — id, user_id, conversation_id, collection_id, question, answer_md, citations_json, confidence, …
- qa_messages — id, user_id, conversation_id, entry_id, role, text, citations_json, created_at, …
- graph_edges — id, user_id, from_doc_id, to_doc_id, weight, kind, created_at, updatedAt
- org_members — id, user_id, member_user_id, invitee_email, role, invited_at, joined_at, created_at, …
- notifications — id, user_id, kind, title, body, link, read_at, created_at, …
- api_tokens — id, user_id, label, hashed_token, last_used_at, created_at, updatedAt
- document_chunks — id, document_id, user_id, chunk_index, body_text, page_number, heading, token_count, …
- devices — id, createdAt, updatedAt, userId, name, pushPlatform, pushSubscription, hasPushSubscription
API (10 handlers)
- api-tokens
api/src/handlers/api-tokens.ts - collections
api/src/handlers/collections.ts - documents
api/src/handlers/documents.ts - graph
api/src/handlers/graph.ts - members
api/src/handlers/members.ts - notifications
api/src/handlers/notifications.ts - qa
api/src/handlers/qa.ts - reports
api/src/handlers/reports.ts - settings
api/src/handlers/settings.ts - sources
api/src/handlers/sources.ts
Subscription tiers
free / pro / team — gated by: maxDocuments, maxQa, advancedFeatures, canExport, retentionDays
Built from 19 @molecule/* packages
@molecule/api-ai-anthropic@molecule/api-ai-embeddings-openai@molecule/api-ai-rag@molecule/api-ai-rag-llm@molecule/api-ai-vector-store-pgvector@molecule/api-database-postgresql@molecule/api-email-templates@molecule/api-emails-mailgun@molecule/api-entitlements@molecule/api-payments-stripe@molecule/api-resource-payment@molecule/api-resource-user@molecule/api-search-meilisearch@molecule/api-uploads-s3@molecule/app-ai-assistant@molecule/app-billing-react@molecule/app-data-table@molecule/app-file-upload@molecule/app-markdown
Required secrets
DATABASE_URLPostgreSQL connection stringANTHROPIC_API_KEYAnthropic API key for ClaudeOPENAI_API_KEYOpenAI API key for embeddingsMEILISEARCH_API_KEYMeilisearch API keyAWS_ACCESS_KEY_IDAWS access key for S3AWS_SECRET_ACCESS_KEYAWS secret key for S3S3_BUCKETS3 bucket for document storage
The @molecule/* packages are Apache-2.0. The app you build from this template is yours to export and self-host. Licensing