Document Processing
OpenCompany provides a complete RAG (Retrieval-Augmented Generation) pipeline for processing documents, generating embeddings, and storing vectors for semantic search.Pipeline Overview
HTTP Scraper
Scrapes links from web pages with support for pagination and date ranges.Modes
Parameters
string
required
URL template. Use
{date} (date mode) or {page} (page mode) placeholders for iteration.select
default:"single"
Iteration mode: single, date, or page
string
default:"a[href$=\".pdf\"]"
CSS selector for links to extract from each fetched page
string
default:"{}"
JSON string of request headers
string
Start date for date mode (YYYY-MM-DD)
string
End date for date mode (YYYY-MM-DD)
string
default:"{date}"
Token in the URL replaced with each date (date mode)
number
default:"1"
First page number (page mode)
number
default:"10"
Last page number, inclusive (page mode)
number
default:"10"
Safety cap on the number of pages fetched (1-1000)
boolean
default:"false"
Route requests through a residential proxy provider. When enabled, exposes
proxy_provider, proxy_country, and session_type (rotating/sticky).Output
Example: Scrape News Archive
File Downloader
Downloads files from URLs in parallel using semaphore-based concurrency.Parameters
string
default:"downloads"
Directory to save downloaded files. Defaults to a
downloads/ folder inside the workflow workspace.number
default:"4"
Maximum parallel downloads (1-32)
boolean
default:"true"
Skip files that already exist
number
default:"60"
Download timeout in seconds (1-600)
Input
Accepts an array ofitems with a url field (from HTTP Scraper), or a plain urls list:
Output
Counts plus afiles array describing the successful downloads:
Document Parser
Parses documents to extract text content using configurable parsers.Parsers
Parameters
select
default:"pypdf"
Parser to use: pypdf, marker, unstructured, beautifulsoup
string
Single file path to parse (takes precedence over
input_dir)string
Directory to scan for files matching
file_patternstring
default:"*.pdf"
Glob pattern used when scanning
input_dir (e.g. *.pdf, *.html)Input
Setfile_path for a single file, or input_dir + file_pattern for a directory scan.
Output
Parser Comparison
Text Chunker
Splits text into overlapping chunks for embedding generation.Strategies
Parameters
select
default:"recursive"
Chunking strategy: recursive, markdown, or token
number
default:"1000"
Target chunk size in characters (100-8000)
number
default:"200"
Overlap between chunks (0-1000)
Input
Accepts adocuments array (with a content field, from Document Parser) or a plain text string:
Output
Choosing Chunk Size
Embedding Generator
Generates vector embeddings from text chunks using various providers.Providers
Parameters
select
default:"huggingface"
Embedding provider: huggingface (local), openai, or ollama (local server)
string
default:"BAAI/bge-small-en-v1.5"
Model name for the chosen provider. Override when switching provider (e.g.
text-embedding-3-small for OpenAI).number
default:"32"
Batch size for embedding generation (1-256)
string
OpenAI API key. Passed as a node parameter (only used when provider is openai).
Input
Accepts achunks array (from Text Chunker), each with a content field:
Output
Parallel arrays:embeddings (one vector per chunk) plus the original chunks echoed back for pairing.
Vector Store
Stores and queries vector embeddings using various backends.Backends
Operations
Parameters
select
default:"chroma"
Vector store backend: chroma, qdrant, or pinecone
select
default:"store"
Operation: store, query, or delete
string
default:"documents"
Collection/index name
number
default:"5"
Number of results for the query operation (1-100)
array
Single query vector for the query operation (from Embedding Generator)
array
Vector IDs to remove for the delete operation
string
default:"./data/vectors"
ChromaDB persistence directory (chroma backend)
string
default:"http://localhost:6333"
Qdrant server URL (qdrant backend)
string
Pinecone API key, passed as a node parameter (pinecone backend)
Store Operation
Input (from Embedding Generator) — pass bothembeddings and chunks:
Query Operation
Query with a precomputed embedding vector (embed your question first, then feed it here):distance for Chroma, score for Qdrant/Pinecone):
Complete RAG Pipeline Example
Workflow
Configuration
-
HTTP Scraper
- URL:
https://docs.example.com/api/{page} - Iteration Mode: page
- Link Selector:
a.pdf-link
- URL:
-
File Downloader
- Output Dir:
./downloads - Max Workers: 10
- Output Dir:
-
Document Parser
- Parser: pypdf
-
Text Chunker
- Strategy: recursive
- Chunk Size: 1000
- Overlap: 200
-
Embedding Generator
- Provider: huggingface
- Model: BAAI/bge-small-en-v1.5
-
Vector Store
- Backend: chroma
- Operation: store
- Collection: api-docs
Querying the Pipeline
Create a separate workflow for querying:Tips
Related
AI Agents
Use RAG context with AI agents
Webhooks
Trigger and respond over HTTP
AI Models
AI providers for generation
Schedulers & Triggers
Run the RAG pipeline on a schedule