Prompt
what should i use for search over pdfs and database tables
Latest observation
Nov 20, 2026
OpenAI APIWeb search: off
For search over PDFs and database tables, the best choice depends on what kind of search you want:
1) If you want semantic / natural-language search
Use:
- Embeddings + vector database
- Good for “find docs like this question”
- Works well on PDF chunks and text from tables
- Examples: pgvector (Postgres), Pinecone, Weaviate, Qdrant, Milvus
This is usually the best default for PDFs.
2) If you want exact keyword / filter search
Use:
- Full-text search
- Good for exact terms, IDs, names, dates
- Examples:
- Postgres full-text search
- Elasticsearch / OpenSearch
- SQLite FTS5
This is usually best for tables when users need precise matching.
3) Best practical setup for most apps
Use a hybrid search approach:
- PDFs: extract text → chunk it → store embeddings in a vector DB
- Tables: index:
- text columns in full-text search
- embeddings for semantic matching
- structured columns as filters
Then combine:
- keyword search
- semantic search
- metadata filters like date, customer, category, status
Recommended stack choices
Simple and strong
- Postgres + pgvector + full-text search
- Great if you want one system for both documents and tables
More scalable search engine
- OpenSearch / Elasticsearch
- Good for hybrid keyword + semantic search, faceting, filtering
Best specialized vector search
- Qdrant or Weaviate
- Pair with Postgres for metadata and tables
My recommendation
If you’re starting out:
- Use Postgres
- Add pgvector
- Use Postgres full-text search
- Store PDFs as chunked text
- Store tables as structured rows plus searchable text
That gives you a clean, cost-effective hybrid search system.
If you want, I can also recommend a specific setup based on your stack, like:
- Python
- Node.js
- AWS
- local-only
- enterprise scale