BM Librarian¶
BM Librarian is a sophisticated Python system for AI-powered biomedical literature research. It combines multiple specialized AI agents with robust database infrastructure to convert research questions into comprehensive, evidence-based medical reports with proper citations.
What is BM Librarian?¶
BM Librarian provides an intelligent platform for biomedical research that goes far beyond traditional literature search:
- Multi-Agent AI Architecture: Specialized agents work together to query, score, cite, and synthesize biomedical literature
- Comprehensive Database: Indexed PubMed abstracts, MedRxiv publications, and open access full texts with semantic search capabilities
- Evidence-Based Reports: Generates publication-style reports with validated citations, preventing AI hallucination
- Counterfactual Analysis: Identifies and integrates contradictory evidence for balanced conclusions
Key Features¶
Fact Checker System¶
Evaluates biomedical statements as yes/no/maybe based on literature evidence. Includes both CLI and desktop GUI with blind mode for unbiased human annotation.
PaperChecker System¶
Validates research abstracts through multi-strategy searches (semantic, HyDE, keyword) and generates counter-reports with evidence-based verdicts.
Multi-Agent Architecture¶
| Agent | Role |
|---|---|
| QueryAgent | Converts natural language to database queries |
| DocumentScoringAgent | Rates document relevance (1-5 scale) |
| CitationFinderAgent | Extracts relevant passages from documents |
| ReportingAgent | Synthesizes citations into publication-style reports |
| CounterfactualAgent | Identifies contradictory evidence |
| EditorAgent | Creates balanced reports integrating all evidence |
| FactCheckerAgent | Evaluates biomedical statements with literature evidence |
| PaperCheckerAgent | Validates abstract claims against contradictory literature |
Advanced Analytics¶
- Multi-model query generation using up to 3 AI models simultaneously for 20-40% improved document retrieval
- Query performance tracking showing which models find most relevant documents
- Counterfactual analysis with progressive audit trails
- Citation validation preventing AI fabrication
Infrastructure¶
- PostgreSQL with pgvector for semantic search
- SQLite-based task queue for memory-efficient processing
- Automated database migrations at startup
- PostgreSQL audit trail tracking complete research sessions
- Local LLM integration via Ollama
Getting Started¶
Requirements¶
- Python 3.12+
- PostgreSQL 12+ with pgvector extension
- Ollama service for local LLM
Installation¶
Usage¶
Research CLI:
GUI Research Application:
Fact-Checker CLI:
Fact-Checker Review GUI:
Configuration GUI:
Stay Updated¶
Check out our Blog for the latest development updates, release announcements, and tutorials.
Open Source¶
BM Librarian is free software released under the GNU General Public License v3.0. Visit our GitHub repository to contribute.