--- title: ConjunctionReservoir Document Chat emoji: 🧠 colorFrom: blue colorTo: indigo sdk: gradio sdk_version: "4.44.0" app_file: app.py pinned: false license: mit short_description: Chat with docs via sentence-level retrieval tags: - rag - retrieval - nlp - neuroscience - document-qa --- # ConjunctionReservoir Document Chat Github is at: https://github.com/anttiluode/conjunctionreservoir Upload any `.txt` or `.pdf` document and chat with it. **What makes this different from standard RAG:** Instead of asking *"do query terms appear somewhere in this chunk?"*, ConjunctionReservoir asks *"do query terms appear in the **same sentence**?"* This is grounded in auditory neuroscience: - **Norman-Haignere et al. (2025):** auditory cortex integration windows are time-yoked (~80ms fixed clocks) - **NMDA receptor logic:** hard AND gate — both inputs must arrive simultaneously - **Vollan et al. (2025):** coverage-maximizing theta sweep for exploration **Benchmark:** 100% Rank-1 rate on conjunction queries vs 60% for BM25 and SweepBrain. ## Usage 1. Upload a `.txt` or `.pdf`, or paste text directly 2. Ask questions — works best for queries requiring two concepts together 3. Adjust the **conjunction threshold** slider to tune precision vs recall 4. Use `:coverage`, `:summary`, `:threshold N` commands in chat ## No dependencies beyond NumPy for retrieval. Generation via HuggingFace Inference API (free).