Spaces:
Runtime error
Runtime error
Commit History
-
fix: all 15 bugs + full agentic RAG pipeline in HF Space
Nikhil Pravin PiseCritical fixes: - OpenSearch client param names aligned (query_text/query_vector) - _execute_search preserves _source as nested dict - health.py: SQLAlchemy text() wrapper + FAISS import path - llm_config: module-level get_synthesizer() function - Redis cache: simplified get(key)/set(key,value) API High priority: - Infinite rewrite loop prevented via retrieval_attempts counter - analyze.py: handles both dict and object results HF Space full pipeline integration: - retrieve_node: retriever-agnostic (FAISS/OpenSearch/BM25) - AgenticContext: retriever field added - grade_documents_node + generate_answer_node: unified doc format - app.py: full guardrail->retrieve->grade->rewrite->generate pipeline - asyncio.get_event_loop() -> get_running_loop()fd5543a
-
feat: production upgrade — agentic RAG, OpenSearch, Redis, Langfuse, Docker, Gradio, Telegram
Nikhil Pravin PisePhase 1: Project structure & dev tooling - pyproject.toml with Ruff/MyPy/pytest config and optional deps - Makefile with dev/test/docker/lint targets - Multi-stage Dockerfile + docker-compose.yml (12 services) - .env.example, .pre-commit-config.yaml Phase 2: Core infrastructure - src/settings.py: hierarchical Pydantic Settings (env-driven) - src/exceptions.py: domain exception hierarchy (15+ classes) - src/database.py: SQLAlchemy engine/session factory - src/models/analysis.py: ORM models (PatientAnalysis, MedicalDocument, SOPVersion) - src/repositories/: data access layer Phase 3: Production services - OpenSearch client with BM25, KNN vector, and hybrid RRF search - Medical synonym analyzer + KNN index mapping (1024d, HNSW) - Multi-provider embedding service (Jina/Google/HuggingFace) with fallback - Redis cache with graceful degradation (NullCache) - Langfuse v3 observability tracer (NullSpan for no-ops) - Ollama REST client with streaming + LangChain integration - Medical-aware tex…1e732dd