Deployment and stretch goals
The capstone moment: ship the PDF chatbot live. Stretch goals turn it from "tutorial project" into "founder-able product".
You built a working bicycle. Now you go ride it in public.
Deploy on Streamlit Cloud as in Module 6.6. Add secrets for OPENAI_API_KEY. Add a requirements.txt:
streamlit
openai
chromadb
pypdf
tiktoken
python-dotenv
Stretch goals:
- Multi-PDF library with per-document selection
- Hybrid search (vector + BM25)
- Reranker (Cohere Rerank or Voyage Rerank)
- Auth via Supabase
- Persistent user history
- Conversational follow-ups ("based on my last question...")
- Image extraction from PDFs (vision LLM call)
- Cost meter in the sidebar
- "Suggested questions" generator from indexed content
- Multi-language support
Hybrid search example:
from rank_bm25 import BM25Okapi
docs = [c["text"] for c in all_chunks]
bm25 = BM25Okapi([d.split() for d in docs])
def hybrid(question, k=10):
vec_top = retrieve(question, k=k)
kw_top = bm25.get_top_n(question.split(), docs, n=k)
return dedupe_and_rerank(vec_top, kw_top)
Quick recall
3 prompts · think before you flip
Prompt 1 of 3
Why a cost meter?
Quiz time
1 question · tap an answer to check it
1. The single highest-trust stretch goal is usually
Finished lesson 9.8?
Mark complete to update your module progress and unlock the streak.
Loading