Spaces:
Running
Running
Commit History
10 days ago
-
feat: 10 free upgrades — streaming upload, cache invalidation, hybrid search, ONNX reranker, SQLAlchemy pool tuning, batch embed cache, semantic chunking, Prometheus histograms, DLQ auto-retry, structured logging+OTel
AkshayM3e047b8
-
Remove forced section headers from SYSTEM_WHITE_BOX — /query returns raw LLM output
AkshayMd134998 -
Parallelize multi-doc retrieval with asyncio.gather
AkshayMa0f0ee1 -
Restore JSON parsing in analyze_document — populate all DocumentAnalysis fields
AkshayM06a5fdf
-
Append verification warning to answer so frontend always shows it
AkshayM1a0d1f5 -
Speed up analyze: use black_box mode (no thinking, 2K tokens) instead of white_box
AkshayM3a19fe3 -
Remove _strip_headers post-processing — let LLM output pass through as-is
AkshayMbededb8 -
Strip headers server-side + stronger prompt to enforce plain-text output
AkshayMf4d05f9 -
Force plain-text output: remove all headers/structure from LLM prompt
AkshayMd62b685 -
Simplify document_agent: drop JSON parsing, return raw LLM output; fix llm.py syntax errors
AkshayM7fdb111 -
fix: strict query-only output in analyze — no extra sections
AkshayMPrompt now tells LLM the JSON keys must be exactly the topics the user asked about. No summary, key_findings, analysis, caveats, or other sections unless the question explicitly requests them.79d0c2f -
feat: query-driven analyze + context window bump
AkshayM- Analyze prompt now instructs LLM to skip 'summary' unless the question asks for one; output keys directly match the query topic. - Fallback summary derived from question text if LLM omits it. - Mercury analyze max_tokens: 4096 -> 8192 - Minimax/custom analyze max_tokens: 8192 -> 16384 (leverages 1M ctx)4127275 -
fix: make analyze JSON structure query-driven instead of rigid template
AkshayMRemoved the hardcoded template forcing all sections (summary, key_findings, methodology, research_gaps, contradictions, open_questions, limitations) for every query. Now the LLM derives which keys to include based on the user's question.6d2e6ad -
fix: normalize all LLM JSON fields + wire cross_doc/per_doc
AkshayMNormalize key_findings/research_gaps/contradictions/open_questions when LLM returns bare string instead of list. Normalize confidence. Wire cross_document_comparison and per_document_summary into DocumentAnalysis (previously silently dropped).3788bc0 -
fix: normalize list-typed limitations/methodology from LLM JSON
AkshayMLLM sometimes returns limitations/methodology as arrays when using response_format=json_object. Convert to bullet list string before passing to DocumentAnalysis constructor.ede9cc4 -
fix: thinking.type enabled for analyze mode + status event
AkshayMTwo remaining 'adaptive' references in analyze modes (minimax + custom) are now 'enabled'. Added SSE status event with reasoning-wait message displayed before streaming begins.84db387
-
feat: provider-based LLM profiles + per-request model switching
AkshayMllm.py: refactored into profile-based architecture with 7 built-in profiles (mercury, gpt5-mini, gpt5, claude-haiku, claude-opus, openrouter, minimax). Dynamic custom profile from LLM_MODEL/LLM_BASE_URL env vars. chat()/astream() accept mode instead of individual params. document_agent.py: all LLM calls use mode-based dispatch. Added apply_profile() for per-request provider switching. schemas.py: model field on QueryRequest and AnalyzeRequest. main.py: GET /llm/profiles endpoint passes model to analyze_document.9a38dd4 -
fix: reduce max_citations_total=10, retrieve_k=15, rerank_top_k=10 + filter chunks <50 chars
AkshayM542c221 -
chore: white-box temperature 0.75 -> 0.3 (stream + analyze)
AkshayMafb97f7 -
feat: remove per-doc citation cap, bump rerank_top_k=20, max_citations_total=50, expose all retrieved citations
AkshayMa2a3e4f -
fix: retrieve_k=20, strengthen system prompts to prevent citation hallucination, add _sanitize_citations post-processing
AkshayM12bcac9 -
fix: black-box concise -> medium reasoning, white-box researcher + analyze -> high
AkshayM438e3b0 -
fix: use high reasoning for verify, medium for gaps + full citation text for gaps
AkshayM13ff565 -
feat: add page_width/page_height to citations for frontend bbox scaling + combined bbox+dimension extraction
AkshayM2c0e3a3 -
fix: tune Mercury 2 params — use valid temp range (0.5-0.75), instant reasoning for black-box, high for white-box, reasoning_summary=false for factual paths
AkshayM835aa37 -
fix: use full citation text in _verify instead of truncated 300-char prefix
AkshayMf545531 -
feat: per-mode reasoning_effort (high for white_box/analyze) + max_tokens 5120
AkshayM964389b
-
chore: increase white_box max_tokens 3048 -> 4096 for more detailed answers
AkshayMc44b309 -
feat: on-demand pdfplumber bbox extraction for citation highlighting
AkshayM49aaae7
-
perf: revert to all-MiniLM-L6-v2, query embed cache, fire-and-forget Cloudinary, pre-warm reranker, reduce top-k
AkshayM1476572
-
perf: upgrade embedding to all-mpnet-base-v2, add cross-encoder reranker, LRU cache, enable PII by default
AkshayM9147527
-
production hardening: circuit breakers, graceful degradation, health checks, parallel uploads, HF Spaces deploy config
AkshayMfc2fe9f
-
fix: query and stream_query now greet back instead of analyzing greetings
AkshayMb7e6bc7 -
fix: analyze endpoint no-ops on greetings and when no documents selected
AkshayMa775719 -
fix: normalize filenames (space/underscore) for doc counting in analyze tab, add document_id to Citation model
AkshayM4bec4c4 -
fix: analyze tab — documents_analyzed now matches actual citation sources, max_tokens=4096, key_findings 4-7
AkshayM15d6801 -
feat: white-box mode now uses max_tokens=3048 and structured answer output
AkshayMa206720 -
feat: /analyze now fairly samples all selected documents, adds cross_document_comparison + per_document_summary fields to response
AkshayMcd3b9ef -
fix: 15 critical/high bugs across codebase
AkshayMCRITICAL: - Wrong import path .async_worker -> ..services.async_worker (Qdrant.py) - search() called run_sync() without await (always crashed) - CancelledError leaves jobs dangling in non-terminal stage HIGH: - circuit_breaker race: state mutations outside lock - llm.py: r.text on async httpx response crashes on error - llm.py: max_tokens=0 silently overridden to 2048 - llm.py: import json inside hot SSE loop - cache.py: MemoryBackend.set() ignores ttl parameter - cache.py: get_or_compute fails on sync callables - bootstrap.py: DB init runs twice (first attempt crashes) - shutdown.py: begin_shutdown races with begin_request - document_agent.py: cost double-counts answer tokens - document_agent.py: multi-hop retrieval asks same question every hop - document_agent.py: stream_query lacks multi-hop and cost_usd - main.py: json.dumps empty list stored as None - main.py: response uses request data instead of DB data - main.py: cloudinary 'skipped' mislabels actual failures - job_queue.py: l…da3be01
-
fix models.py: match Neon schema varchar sizes, add email unique constraint
AkshayM167c070