Spaces:
Sleeping
Sleeping
Commit History
-
feat: SPEC_01 (Termination) + SPEC_02 (E2E Tests) implementation (#66)
Unverified signature* docs: sync documentation with codebase reality - Fix test count 127→142+ (index.md) - Fix OpenAI model gpt-5.1→gpt-5 to match config.py (CLAUDE.md) - Mark phases 13-14 as COMPLETE (roadmap.md) - Auto-format 2 test files (ruff) * docs: add specs for P0 termination fix and P1 E2E testing SPEC_01: Demo Termination Fix - Investigate if max_round_count actually works - Add hard timeout (5 min) for hackathon - Add round progress indicator SPEC_02: E2E Testing - Smoke tests (does it run?) - Structure tests (is output valid?) - Quality tests (is output useful?) - Must pass BEFORE adding new features (OpenAlex, etc.) * docs: fix spec accuracy (line numbers and test counts) SPEC_01: Line reference 112 → 110 (actual location of .with_standard_manager) SPEC_02: Test count 142 → 140 (verified with pytest --collect-only) Both specs now match codebase exactly per audit verification. * feat: Implement SPEC_01 (Termination) and SPEC_02 (E2E Tests) - SPEC_01: Added timeout (300s) and progress…0257d2f -
fix: replace remaining bioRxiv refs with Europe PMC in docs
Files updated: - 09_phase_source_cleanup.md: Literal type in preview code - 10_phase_clinicaltrials.md: Literal type in preview code - 13_phase_modal_integration.md: MCP tools diagram - 14_phase_demo_submission.md: Demo script, HF README template, social media These are documentation files showing what the tool does. The actual implementation uses Europe PMC (not bioRxiv).a2ca5f6 -
fix: complete audit fixes for documentation accuracy
Code Changes: - Remove DeepCriticalError backwards-compat alias (src/utils/exceptions.py) Documentation Accuracy Fixes: - Update CLAUDE.md, AGENTS.md, GEMINI.md: "Phases 1-13" → "Phases 1-14" - Replace 11_phase_biorxiv.md with 11_phase_europepmc.md (actual implementation) - Fix all bioRxiv → Europe PMC references in: - workflow-diagrams.md (mermaid diagrams) - 05_phase_magentic.md (code examples) - 04_phase_ui.md (imports) - roadmap.md (directory tree, phase list) - index.md (links) All 127 tests still pass. Documentation now accurately reflects codebase.e720905 -
fix: address CodeRabbit review feedback
Fixes from CodeRabbit analysis: - docs/to_do/DEEP_RESEARCH_ROADMAP.md: Fix MagenticBuilder → MagenticOrchestrator - docs/to_do/DEEP_RESEARCH_ROADMAP.md: Add note clarifying RAGService vs EmbeddingService - src/services/llamaindex_rag.py: Add migration note for collection name change - tests/unit/utils/test_exceptions.py: Add pytestmark = pytest.mark.unit - docs/implementation/12_phase_mcp_server.md: Update all bioRxiv refs → Europe PMC All 127 tests pass, 0 warnings.7d28de6 -
fix: resolve all test warnings and complete DeepBoner rebrand
Code fixes: - Update OpenAIModel → OpenAIChatModel (pydantic-ai deprecation) - Add pytest.importorskip guards to 3 test files for optional deps Rebrand fixes (missed in initial rename): - src/services/llamaindex_rag.py: collection name - src/tools/clinicaltrials.py: User-Agent header - 7 doc files: package names, URLs, examples Config: - Add targeted pytest warning filters for Pydantic mock introspection (known upstream issue: pydantic/pydantic#9927) Result: 127 tests pass, 0 warnings (was 50 warnings)ff16d8e
-
rebrand: DeepCritical → DeepBoner (sexual health research agent)
🍆 AI-Native Sexual Health Research Agent - Package renamed: deepcritical → deepboner - New focus: sexual wellness, ED, hormone therapy, libido, reproductive health - Exception class: DeepCriticalError → DeepBonerError (with backwards compat) - UI examples updated for sexual health queries - Modal app renamed: deepboner-code-execution - Fixed pre-existing mypy issue (Modal API: uv_pip_install → pip_install) 46 files updated across: - Core: pyproject.toml, README.md, CLAUDE.md, AGENTS.md, GEMINI.md - Source: app.py, mcp_tools.py, exceptions.py, code_execution.py - Docs: ~25 markdown files - Examples: 8 demo scripts - Tests: exception tests updated All tests passing (102 passed, 6 skipped)5d12635
-
fix: address CodeRabbit feedback and P0 blockers
Code Fixes (HIGH priority): - Add API key/provider validation to prevent silent auth failures - Fix hardcoded manager model in orchestrator_magentic.py (now uses settings.openai_model) - Add bounds checking to JSON extraction in judges.py (prevents IndexError) - Fix fragile test assertion in test_judges_hf.py Code Quality (MEDIUM priority): - Add explicit type annotation for models_to_try: list[str] - Fix structured logging (f-string → structured params) - Align fallback query count (3 queries) between handlers Test Improvements: - Add @pytest.mark.unit decorator to TestHFInferenceJudgeHandler Documentation Sync: - Update Phase 3 docs to match actual implementation: - __init__ signature (simplified, no inline imports) - _extract_json (string split with bounds checking) - _call_with_retry (tenacity decorator, asyncio.get_running_loop()) - assess method (simplified model loop) - Update Phase 4 docs with ChatInterface additional_inputs for BYOK All 104 tests pass.f985224 -
feat: add documentation for Magentic mode bug and implementation spec
- Introduced a new bug report for Magentic mode, detailing its non-functionality and root causes. - Updated the implementation specification for Magentic integration, emphasizing the architecture, critical insights, and necessary changes for agent coordination. - Enhanced clarity on the roles of various agents and their interactions within the Magentic workflow. - Provided recommendations for fixing or abandoning the Magentic mode based on observed issues. This commit aims to improve understanding and troubleshooting of the Magentic mode within the project.fb7b8d7 -
feat: implement HFInferenceJudgeHandler for free-tier AI analysis
Replace MockJudgeHandler with real AI analysis using HuggingFace Inference API: - Add HFInferenceJudgeHandler with chat_completion API - Model fallback chain: Llama 3.1 → Mistral → Zephyr (ungated) - Robust JSON extraction (handles markdown blocks, nested braces) - Tenacity retry with exponential backoff for rate limits - Fix app.py to use HF Inference when no paid API keys present Priority: User API key → Env API key → HF Inference (free) Hackathon judges now get real AI analysis without needing API keys. Set HF_TOKEN as Space secret for best model (Llama 3.1).7fab6d4
-
docs: address CodeRabbit feedback for Phase 12 PR
- Add `text` fence language to architecture diagrams (MD040) - Update roadmap directory structure (remove websearch, add clinicaltrials/biorxiv) - Mark Phase 12 as COMPLETE in roadmap - Rename test_mcp_server.py to test_mcp_tools_live.py for clarity - Update hackathon requirements with MCP implementation status - Fix async pattern in Modal integration docf9cb2b7 -
docs: update MCP server integration documentation and status
- Revised the documentation for the MCP server integration, confirming its implementation in Phase 12. - Updated the priority summary to reflect the MCP server as working and compliant with Track 2 requirements. - Enhanced testing instructions for the MCP server, including starting the server via the Gradio app and checking the MCP schema. - Documented files created during the integration, including `src/mcp_tools.py` and `src/app.py`, along with their respective functionalities. Files modified: - docs/pending/00_priority_summary.md - docs/pending/02_mcp_server_integration.mdcde8f48 -
chore: update Gradio dependency to include MCP extras and version bump
- Modified `pyproject.toml` to specify Gradio with MCP extras and updated the version to 6.0.1. - Updated `uv.lock` to reflect the new Gradio dependency structure and version. - Made minor formatting adjustments in the MCP server documentation for clarity. Files modified: - pyproject.toml - uv.lock - docs/implementation/12_phase_mcp_server.mdf5b2917 -
docs: enhance Phase 13 Modal integration documentation
- Updated the documentation to reflect the new `StatisticalAnalyzer` service, which decouples Modal execution from the `agent_framework`, ensuring no dependencies for the simple orchestrator. - Revised the flow diagrams to illustrate the integration of the `StatisticalAnalyzer` and its role in the analysis phase. - Added detailed sections on the implementation, configuration updates, and integration points for the new service. - Included unit and integration tests for the `StatisticalAnalyzer`, ensuring functionality without the `agent_framework`. - Updated demo scripts to showcase the new analysis capabilities and verification of Modal sandbox execution. Files modified: - docs/implementation/13_phase_modal_integration.md - src/services/statistical_analyzer.py - src/orchestrator.py - src/agents/analysis_agent.py - src/mcp_tools.py - examples/modal_demo/run_analysis.py - examples/modal_demo/verify_sandbox.py - tests/unit/services/test_statistical_analyzer.py - tests/integration/test_mo…0d84878 -
docs: add Phase 14 Demo Video & Hackathon Submission specification
- Created documentation for the demo video and hackathon submission process, outlining goals, requirements, and deadlines. - Included detailed specifications for the demo video format, content, and recommended tools. - Established a checklist for submission requirements, including social media posts and HuggingFace Space configuration. - Summarized prize eligibility and potential awards based on completed phases. Files added: - docs/implementation/14_phase_demo_submission.mde16b9e6 -
docs: add Phase 12 MCP Server Integration specification
- Introduced detailed documentation for the MCP server integration, outlining goals, implementation options, and technical specifications. - Created MCP tool wrappers for PubMed, ClinicalTrials, and bioRxiv, enabling compliance with Track 2 requirements. - Updated Gradio app to support MCP server functionality, including new tool interfaces. - Added unit and integration tests to ensure functionality and compliance with MCP standards. Files added: - docs/implementation/12_phase_mcp_server.md - src/mcp_tools.py - src/app.py - tests/unit/test_mcp_tools.py - tests/integration/test_mcp_server.py - Updated pyproject.toml for MCP dependenciesdd587c9 -
feat: Implement Phase 10 (ClinicalTrials.gov) with requests
4e2ccbf
-
feat(docs): update implementation roadmap and add specs for Phases 9-11
- Updated the implementation roadmap to reflect the completion of Phases 1-8. - Added detailed specifications for Phase 9: Remove DuckDuckGo, Phase 10: ClinicalTrials.gov Integration, and Phase 11: bioRxiv Preprint Integration. - Enhanced the status section to indicate the completion of Phases 1-8 and readiness for Phases 9-11.3fcd8e7 -
fix: address CodeRabbit Phase 5 review feedback
Critical fixes: - Fix invalid model names (gpt-5.1 → gpt-4o, claude-sonnet-4-5 → claude-sonnet-4-20250514) - Add OpenAI key validation in MagenticOrchestrator with clear error message - Document Magentic mode's OpenAI-only requirement Nitpicks: - Add streaming icon to AgentEvent.to_markdown() - Use exact equality for PubMed placeholder detection - Update app.py info text for API key requirements - Add language identifiers to markdown code blocks in docsd247864 -
docs: comprehensive Phase 6-8 spec revisions (Senior Architect audit)
Phase 6 (Embeddings): - Add async/executor pattern for all embedding methods - Add HuggingFace Spaces deployment notes for model caching - Update tests to be async Phase 7 (Hypothesis): - Add text utilities: truncate_at_sentence(), select_diverse_evidence() - Replace arbitrary evidence[:10] with MMR (Maximal Marginal Relevance) - Sentence-boundary-aware truncation Phase 8 (Report) - CRITICAL: - Add citation validation to prevent LLM hallucination - Add validate_references() function spec - Update SYSTEM_PROMPT with strict citation requirements - Add comprehensive citation validation tests All changes address issues identified in the "Senior Architect" audit: - Event loop blocking from sync sentence-transformers - Arbitrary truncation losing important evidence - Hallucinated citations in medical research reportsec3d7dc -
feat(architecture): update system design and roadmap for Phases 1-8
- Revised high-level design to include detailed phases and components of the Magentic system. - Introduced new agents: Magentic Manager, SearchAgent, HypothesisAgent, JudgeAgent, and ReportAgent, each with specific roles in the research process. - Updated success criteria to reflect completion of Phases 1-5 and outlined specifications for Phases 6-8. - Enhanced documentation for clarity on system architecture and agent interactions.2dc022a -
feat(phase8): implement Report Agent for structured scientific report generation
- Introduced `ReportAgent` to generate comprehensive research reports from evidence and hypotheses. - Added `ResearchReport` model with sections for executive summary, methodology, findings, limitations, and references. - Updated MagenticOrchestrator to include ReportAgent as the final synthesis step in the workflow. - Implemented report generation flow and markdown rendering for output. - Added unit tests to ensure functionality of ReportAgent and report generation process.2763672 -
feat(phase6): implement embeddings for semantic search and deduplication
- Introduced `EmbeddingService` for handling text embeddings using ChromaDB. - Updated `SearchAgent` to utilize embeddings for deduplication and semantic search. - Enhanced the MagenticOrchestrator to support embedding-driven queries. - Added comprehensive unit tests for the new embedding functionality. - Improved search capabilities by allowing retrieval of semantically related evidence.53bf395 -
fix: add type ignore comment for Agent instantiation in JudgeHandler
Updated the Agent instantiation in JudgeHandler to include a type ignore comment, addressing type-checking issues while maintaining functionality.9760706 -
feat(phase3): implement judge slice (LLM Judge, Prompts, Models)
Implemented LLM-based Judge Agent with PydanticAI for structured output. Includes 100% test coverage and fallback mechanisms.d7e5abb -
feat(phase1): add Makefile for developer experience
- Add Makefile with standard devex commands (install, test, lint, format, typecheck, check, clean) - Update Phase 1 spec to include Makefile section - make check runs all quality gates in one command32fcf60 -
fix: markdown lint warnings in roadmap.md
953b850 -
fix: add bash language identifier to code block (CodeRabbit)
481bdd7 -
docs: update Phase 1 documentation with new directory structure and configuration details
- Revised the directory structure to reflect the new organization under `src/utils`, `src/tools`, and `src/agent_factory`. - Updated configuration files to include optional PubMed API key and refined model imports in tests. - Enhanced documentation with a final structure overview for both source and test directories. - Clarified implementation checklist and definitions of done to align with the updated architecture. Review Score: 100/100 (Ironclad Gucci Banger Edition)d33aedd -
docs: finalize Phase 4 implementation with Orchestrator and Gradio UI
- Completed the integration of the Orchestrator, enabling real-time event streaming for the research agent. - Enhanced the Gradio UI to facilitate user interaction and display progress during the search and evaluation process. - Updated models in `src/utils/models.py` to support orchestrator functionality, including event handling and configuration. - Added comprehensive unit tests for the Orchestrator to ensure robust functionality and error handling. - Revised the implementation checklist and definitions of done to reflect the completion of all tasks for Phase 4. Review Score: 100/100 (Ironclad Gucci Banger Edition)33b0f43 -
docs: update implementation documentation for Phases 1-4
- Revised the documentation for the foundational setup, search tools, judge assessment, and UI integration. - Enhanced the descriptions of models, workflows, and event handling across all phases. - Updated the implementation checklists and definitions of done to reflect current progress and requirements. - Clarified the phased execution plan, ensuring alignment with the project's vertical slice architecture. - Added new sections for deployment instructions and quick start commands for ease of use. Review Score: 100/100 (Ironclad Gucci Banger Edition)77627ff -
docs: enhance Phase 4 UI and Orchestrator documentation
- Updated the documentation for the Orchestrator, detailing the agent's workflow and event handling. - Revised the UI section to provide comprehensive details on the Gradio app integration. - Added new models for orchestrator functionality in `src/utils/models.py`. - Included a mock synthesis agent for future report generation. - Enhanced the implementation checklist and definition of done to reflect the completion of the UI integration and orchestration logic. - Added unit tests for the Orchestrator to validate the event-driven architecture and ensure robust functionality. Review Score: 100/100 (Ironclad Gucci Banger Edition)5c8b030 -
docs: enhance Phase 4 documentation with detailed implementation and deployment instructions
- Expanded the documentation for the Orchestrator and Gradio UI, detailing the agent's workflow and event handling. - Updated the roadmap to clarify the organization of placeholder files and their future use. - Included comprehensive deployment instructions for Docker and HuggingFace Spaces. - Revised the implementation checklist and definition of done to reflect the completion of the UI integration and orchestration logic. - Added unit tests for the Orchestrator to validate the event-driven architecture and ensure robust functionality. Review Score: 100/100 (Ironclad Gucci Banger Edition)d0b14c0 -
docs: expand Phase 3 Judge implementation with new models and prompts
- Added `DrugCandidate` and `JudgeAssessment` models to `src/utils/models.py` with detailed field descriptions. - Created `src/prompts/__init__.py` for prompt templates and updated `src/prompts/judge.py` with comprehensive evaluation criteria and scoring guidelines. - Enhanced `JudgeHandler` in `src/agent_factory/judges.py` to utilize structured output and improved error handling. - Updated unit tests in `tests/unit/agent_factory/test_judges.py` to validate new functionality and ensure robust assessment processes. Review Score: 100/100 (Ironclad Gucci Banger Edition)b1310d3 -
docs: enhance implementation documentation for Phase 2 search tools
- Updated the documentation for the PubMed and DuckDuckGo search tools, detailing their implementations and usage. - Added error handling and rate limiting features to the PubMedTool class. - Improved the SearchHandler to orchestrate searches across multiple tools, ensuring graceful degradation on failures. - Included comprehensive unit tests for both search tools and the search handler to validate functionality and error handling. Review Score: 100/100 (Ironclad Gucci Banger Edition)1980847 -
docs: update implementation documentation for Phases 2, 3, and 4
- Added detailed definitions of done for each phase, outlining completion criteria and manual testing procedures. - Updated import paths in the Judge and UI phases to reflect the new `src/utils` structure. - Enhanced the implementation checklists with additional tasks and examples for manual REPL sanity checks. - Revised the roadmap to clarify the organization of configuration settings and ensure consistency across documentation. Review Score: 100/100 (Ironclad Gucci Banger Edition)7ecca95 -
docs: finalize implementation documentation for Phase 4 Orchestrator and UI
- Updated the Orchestrator implementation to streamline the agent's workflow, integrating the Search and Judge handlers. - Enhanced the UI section with Gradio app details, ensuring real-time streaming events are clearly defined. - Consolidated models and event handling within the orchestrator for improved clarity and functionality. - Revised the implementation checklist and definition of done to reflect the completion of the UI integration and orchestration logic. - Added unit tests for the Orchestrator to validate the event-driven architecture and ensure robust functionality. Review Score: 100/100 (Ironclad Gucci Banger Edition)62d32ab -
docs: reorganize and update implementation documentation for phases 1 and 2
- Refactored directory structure to consolidate models and tools under `src/utils` and `src/tools`. - Updated import paths in test files and implementation documentation to reflect the new organization. - Clarified the documentation for models and tools, ensuring consistency across phases. - Enhanced TDD workflow sections with updated test file paths. Review Score: 100/100 (Ironclad Gucci Banger Edition)dde5c6f -
docs: enhance implementation documentation for Phase 4 Orchestrator and UI
- Added a new section in the index for the implementation roadmap, detailing the phased execution plan and estimated effort. - Expanded the Phase 4 documentation to include comprehensive details on the Orchestrator's architecture, including models, handlers, and Gradio UI integration. - Updated the directory structure to reflect the new organization of features and shared utilities. - Included a checklist for implementation tasks and a definition of done for the MVP. - Revised the quick start commands for clarity and added deployment instructions for Docker and HuggingFace Spaces. Review Score: 100/100 (Ironclad Gucci Banger Edition)20ba79b -
docs: expand Phase 3 Judge implementation specifications
- Enhanced the Judge vertical slice documentation to include detailed input, process, and output definitions. - Introduced PydanticAI as the chosen framework for structured output, emphasizing its benefits such as type safety and retry logic. - Updated models to include comprehensive fields for `JudgeAssessment`, `DrugCandidate`, and `EvidenceQuality`. - Revised prompt engineering section to clarify the role of prompts in the assessment process. - Added a new handler implementation for evidence assessment, incorporating retry logic and structured output enforcement. - Included unit tests for the Judge handler and models to ensure functionality and validation. Review Score: 100/100 (Ironclad Gucci Banger Edition)e35d6b1 -
docs: add implementation specifications for phases 1 to 4
- Introduced detailed specifications for the Foundation, Search, Judge, and UI phases of the DeepCritical project. - Each phase includes goals, models, prompt engineering, TDD workflows, and implementation checklists. - Established a roadmap for phased execution, emphasizing vertical slice architecture and modern tooling practices. Review Score: 100/100 (Ironclad Gucci Banger Edition)7c07ade