Qwen 3.5, Ollama and Docling: local financial PDF RAG
Build a financial PDF RAG app with Ollama, Docling and LangGraph, including hybrid search, streamed citations and a 1,024-token chunk limit.
Player not loading? Watch on YouTube
This tutorial walks through a financial-document RAG application built around Ollama, Docling and LangGraph. A Streamlit interface handles PDF uploads and chat, while FastAPI manages ingestion jobs and streams answers, source references and pipeline stages through server-sent events. The title identifies Qwen 3.5 as the model used.
The ingestion pipeline converts PDFs to Markdown, detects table structures and splits content by headings, with a 1,024-token chunk limit. An LLM adds context to each chunk before storage in a local Supabase database. The demonstrated configuration disables OCR; image descriptions are optional. Retrieval combines full-text search with vector embeddings through pgvector, followed by FlashRank reranking.
The speaker presents the stack as private and able to work offline, but notes that the first startup downloads models. The project includes a root-level Docker Compose configuration, and the walkthrough also shows starting the database, backend and interface separately.
Two examples query Nvidia revenue growth and Apple's cash balances. The speaker compares the answers with the reports and finds matches in those examples. These checks illustrate source-backed retrieval with a local LLM; they do not establish accuracy across financial documents.