Overview
The Document Store feature allows you to:- Store and organize documents for multiple chatflows
- Process documents with various loaders (PDF, CSV, text, web scraping, etc.)
- Configure text splitters for optimal chunking
- Preview and edit document chunks before upserting
- Upsert documents to vector stores with embeddings
- Query and test retrieval performance
- Track upsert history and configurations
Creating a Document Store
Adding Documents
Once you’ve created a document store, you can add documents using various loaders:// Example: PDF loader configuration
{
"textSplitter": "RecursiveCharacterTextSplitter",
"chunkSize": 1000,
"chunkOverlap": 200,
"metadata": {
"source": "user_manual.pdf"
}
}
Configuring Vector Store
To enable retrieval, you need to configure embeddings and a vector store:text-embedding-ada-002, text-embedding-3-small, text-embedding-3-largeincremental, fullThe upsert process can take several minutes depending on the number of chunks and the embeddings provider’s rate limits.
Managing Document Chunks
You can view and edit individual document chunks:View Chunks
From the document store detail page, click View & Edit Chunks for any loader to see all chunks:Edit Chunks
Click on any chunk to edit its content or metadata:- Modify chunk text
- Update metadata fields
- Delete unwanted chunks
Refresh Documents
For documents that change over time, use the Refresh option to re-process and upsert all loaders.Querying the Document Store
Test your retrieval setup with the built-in query interface:similarity: Cosine similarity searchmmr: Maximum Marginal Relevance
Using Document Store in Chatflows
To use your document store in a chatflow:- Add a Retriever node to your canvas
- Connect it to your Vector Store node
- In the Vector Store configuration, select your Document Store
- The chatflow will automatically use the embedded documents
Document Store API
Flowise provides REST APIs for programmatic access to document stores.Upsert Documents via API
List Document Stores
Get Specific Document Store
Delete Document Store
For the complete API reference, see the Document Store API documentation.
Document Store Status
Document stores have different statuses indicating their state:- NEW: Newly created, no documents added
- STALE: Documents added but not yet processed
- SYNCED: Documents processed and synced
- UPSERTED: Documents embedded and stored in vector store
- UPSERTING: Currently upserting to vector store
- SYNC: Chunks are synced with vector store
Best Practices
Chunk Size Optimization
Choose chunk sizes based on your use case:- Small chunks (200-500 tokens): Better for precise retrieval
- Medium chunks (500-1000 tokens): Balanced approach
- Large chunks (1000-2000 tokens): More context per chunk
Metadata Strategy
Add metadata to improve filtering and retrieval:Document Organization
Create separate document stores for:- Different knowledge domains
- Various access levels
- Multiple languages
- Distinct projects or clients
Monitoring and Maintenance
- Regularly review document store usage in chatflows
- Monitor upsert history for errors
- Update documents when source content changes
- Clean up unused document stores
Troubleshooting
Chunks Not Appearing
- Verify the document was processed successfully
- Check that text splitter configuration is correct
- Ensure file format is supported by the loader
Upsert Failures
- Verify embeddings provider credentials
- Check vector store connection settings
- Review API rate limits
- Examine error logs in upsert history
Poor Retrieval Quality
- Adjust chunk size and overlap
- Try different text splitters
- Experiment with embeddings models
- Refine search parameters (top_k, search type)
