Spaces:
Sleeping
Sleeping
Commit History
-
Refactor test cases for improved readability and consistency
sethmcknight- Simplified multi-line strings in test cases to single-line format for better readability. - Consolidated test case structures by removing unnecessary line breaks. - Updated assertions to be more concise and maintainable. - Added new integration tests for search caching and embedding warmup functionality. - Ensured all tests maintain consistent formatting and style across the test suite.159faf0
-
Docs: Update changelog, README, and tests for search threshold fix
Tobias Pasquale- Add comprehensive changelog entry #029 documenting the search threshold issue resolution - Update README with recent fixes section explaining the similarity calculation correction - Fix test expectations to match new similarity formula: max(0.0, 1.0 - (distance / 2.0)) - Update integration test thresholds from 0.3 to 0.2 for realistic similarity scores - Remove temporary diagnostic files used during debugging All tests passing: - 12/12 search service tests ✅ - 8/8 vector store tests ✅ - Integration tests functional ✅ Production impact: RAG system now fully operational with proper vector retrievalf351b2b -
Fix: Lower search thresholds to enable vector retrieval
Tobias Pasquale- Reduce search_threshold from 0.1 to 0.0 - Reduce min_similarity_for_answer from 0.15 to 0.05 - This enables retrieval of semantically relevant documents that were previously filtered out - Fixes issue where valid queries like 'Can I work from home?' returned zero contextc89ac71
-
style: Apply black formatting to linting fixes
Tobias PasqualeAuto-formatted by pre-commit hook: - tests/test_guardrails/test_enhanced_rag_pipeline.py - src/guardrails/response_validator.py - src/guardrails/guardrails_system.py All files now pass black, isort, and flake8 validationa52e676 -
Complete Issue #24: Guardrails and Response Quality System✅ IMPLEMENTATION COMPLETE - All acceptance criteria met:🏗️ Core Architecture:- 6 comprehensive guardrails components- Main orchestrator system with validation pipeline - Enhanced RAG pipeline integration- Production-ready error handling🛡️ Safety & Quality Features:- Content safety filtering (PII, bias, inappropriate content)- Multi-dimensional quality scoring (relevance, completeness, coherence, source fidelity)- Automated source attribution and citation generation- Circuit breaker patterns and graceful degradation- Configurable thresholds and feature toggles🧪 Testing & Validation:- 13 comprehensive tests (100% pass rate)- Unit tests for all core components- Integration tests for enhanced pipeline- API endpoint testing with full mocking- Performance validated (<10ms response time)📁 Files Added:- src/guardrails/ (6 core components)- src/rag/enhanced_rag_pipeline.py- tests/test_guardrails/ (comprehensive test suite)- enhanced_app.py (demo Flask integration)- ISSUE_24_IMPLEMENTATION_SUMMARY.md🚀 Production Ready:- Backward compatible with existing RAG pipeline- Flexible configuration system- Comprehensive logging and monitoring- Horizontal scalability with stateless design- Full documentation and type hintsAll Issue #24 requirements exceeded. Ready for production deployment.
Tobias Pasquale135f0d6 -
Fix: Complete CI/CD formatting compliance
Tobias Pasquale- Apply black code formatting to 12 files - Fix import ordering with isort - Remove unused imports (Union, MagicMock, json, asdict, PromptTemplate) - Fix undefined variables in test_chat_endpoint.py - Break long lines in RAG pipeline and response formatter - Add noqa comments for prompt template strings - Resolve all 19 flake8 E501 line length violations - Ensure full pre-commit hook compliance All code formatting issues resolved for successful pipeline deployment.508a7e5 -
feat: complete Phase 3 Issue #23 LLM integration and RAG pipeline
Tobias Pasquale- Add multi-provider LLM service (OpenRouter/Groq) with fallback support - Implement complete RAG pipeline with context management and response formatting - Add /chat POST endpoint for conversational AI interactions - Add /chat/health GET endpoint for RAG pipeline monitoring - Create comprehensive prompt templates for corporate policy Q&A - Add context optimization with length management and deduplication - Implement 90+ comprehensive tests with TDD approach - Update requirements.txt with requests dependency - Update CHANGELOG.md with Phase 3 completion status Components: - src/llm/: LLM service, context manager, prompt templates - src/rag/: RAG pipeline orchestration and response formatting - app.py: Flask endpoints integration with full error handling - tests/: Comprehensive test coverage for all new functionality Resolves #23c280a92