Skip to content
프로젝트

NingyuSUN/bioai-evidence-validator

GitHub에서 보기

소개

Evidence validation and policy engine for AI-assisted biological curation

AI 및 머신러닝

이 수치를 측정하는 방법

측정된 스타 증가

in 24h
0
in 7 days
기록 수집 중
in 15 days
기록 수집 중
in 1 month
기록 수집 중

서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.

README.md

Original

BioAI Evidence Validator v0.9.0. Deterministic gate catches 100% of flawed AI bio claims: 198 of 714 first claims had an identifier, name or quotation error, and 0 of 663 admitted claims had one after feedback. 12 of 12 fabricated quotations caught. BioCuration-Bench v2 J = 0.987 across 300 real papers with 0% leak.

PyPI v0.9.0 CI on main Docs and leaderboards Python 3.11+ Apache-2.0 license

Quickstart · Architecture (5 Layers) · Leaderboard v2 (300 Papers) · Hallucination Atlas (100 PMC) · ACMG Triage v2 (200 ClinVar) · Blind Review App · EvidPort

BioAI Evidence Validator deterministically audits AI-generated biomedical claims against SHA-256-pinned sources and decides per intended use whether each record can enter a research summary or curated catalog. Across 40 papers, 198 of 714 first-pass claims from six models carried a wrong identifier, name, or quotation—and 0 of 663 admitted claims retained one after guided feedback (extraction study); on 300 sealed PMC items, the hybrid stack reaches BioCuration-Bench v2 J = 0.987 (100% recall, 0.0% leakage).

Why BioAI Evidence Validator?

  • Catch plausible citations to the wrong passage or retracted paper. Real PMIDs resolve even when quoted text is fabricated or retracted; LiteratureGrounder + EvidPort rejected 12/12 fabricated quote controls and caught 100% of unwatermarked retractions missed by blind LLMs (1.9% recall). Quote controls
  • Return actionable corrections without letting models game conflicts. Fixable ontology/HGVS/quote errors return exact replacement IDs (e.g. pancreatic delta cell CL:0000173, not CL:0002335), while contradictions and semantic drift route straight to humans. Single-cell benchmark
  • Decide separately per downstream use. The same ClinGen classification can qualify for research_summary while curated_catalog enforces orthogonal evidence and human sign-off. Gene–disease profile

30-Second Quickstart

pip install bioai-evidence-validator
curl -fsSLO https://raw.githubusercontent.com/NingyuSUN/bioai-evidence-validator/v0.9.0/examples/literature_claim/llm_only.json
bioevidence validate llm_only.json --profile literature-claim
# -> "overall_status": "review_required", "reason_codes": ["BEV008"]  (exit code 2; 0=admit, 1=reject, 3=config)

Inspect per-use policy decisions in Python, or gate pull requests in GitHub Actions (draft format · notebook):

import json
from pathlib import Path
from bioevidence_validator import validate_record

report = validate_record(json.loads(Path("llm_only.json").read_text(encoding="utf-8")), profile="literature-claim")
print(report["overall_status"], report["use_decisions"][0]["reason_codes"])  # review_required ['BEV008']
- uses: NingyuSUN/[email protected]
  with: { files: "records/**/*.yaml", format: draft, profile: literature-claim, fail-on: review }

Architecture & How It Works

LinkML is only Layer 1 (the typed record contract). A 5-layer deterministic verification pipeline separates one-time online source pinning (bioevidence ground / EvidPort) from 100% offline byte-level recomputation ($0 local CPU, 0.48 ms/item):

BioAI Evidence Validator 5-layer architecture: online source pinning into a content-addressed SHA-256 SnapshotStore feeds Layer 1 LinkML contract and integrity, Layer 2 six offline source grounders, Layer 3 conservative semantic support, Layer 4 declarative per-use policy with an anti-gaming feedback loop, and Layer 5 a living source_verified and blinded human_gold reference layer.

Layer Core Modules Deterministic Guarantee Rule Codes / CLI
L1 · Contract & Integrity draft.py, engine.py, schema/ Compiles YAML drafts or JSON against LinkML (JSON Schema 2020-12); rejects duplicate IDs, dangling refs, unused evidence, and nonfinite numbers fail-fast. SCHEMA, RECORD_INTEGRITY
L2 · Six Offline Grounders grounding.py, literature.py, evidence_library.py, identifiers.py, tables.py, crosscheck.py Re-hashes SnapshotStore bytes; verifies PMID/DOI retractions & JATS quotes, EvidPort evidence:cv_<sha>#b<n> blocks & stdio MCP, OBO roots/labels, HGNC, RefSeq HGVS, Decimal half-ULP cells, and ClinVar/VBO snapshots. BEV014–BEV019, BEV023–BEV025 + replacement IDs
L3 · Semantic Support Guard semantic.py, semantic_support.py Catches polarity flips, causal inflation (associated with to causes), hedging, mouse-to-human scope creep, and Decimal stat bounds (p, OR, HR, %, fold), with optional hybrid evaluation on ambiguous quotes. BEV022, BEV027 (abstain to review)
L4 · Per-Use Policy & Feedback engine.py, profiles/*.yaml, feedback.py Evaluates research_summary, curated_catalog, and training_data independently with SHA-256 audit hashes; sends fixable grounder errors back to the LLM and routes conflicts straight to humans. BEV001–BEV013, BEV020–BEV021; Exit 0/1/2
L5 · Living Reference & Gold reference.py, reference_ui.py, review.py, audit.py Auto-promotes grounded admissions to Tier 1 source_verified (auto-revoking on BEV019 retraction) and builds blinded Tier 2 human_gold HTML review packets with Krippendorff's α / Cohen's κ and Clopper–Pearson bounds. bioevidence reference <build|promote|init-gold|freeze>
Anti-gaming feedback contract (feedback.py) & 5-layer claim walkthrough
  • Fixable grounder defects return to the model: Wrong ontology IDs (BEV017/BEV023), malformed HGVS (BEV024), or unverified quotes return the exact field path and replacement term; feedback.carry monotonically locks already-verified evidence across revisions so nothing is silently dropped.
  • Judgment & policy flags go straight to humans: Contradictions (BEV004/BEV025), semantic warnings (BEV022/BEV027), and review policies (BEV008–BEV013) never return to the model, removing any incentive to delete conflicting evidence.
  • End-to-end trace (ABL1 / PMID:28103578): (1) bioevidence ground pins the PMC JATS XML by SHA-256; (2) L1 passes schema while L2 flags mismatched DOID:9119 (-> DOID:9952) and a paraphrased quote; (3) L4 returns only those two fixable errors, L2 verifies the revised ID + verbatim quote, and L3 clears polarity/scope under BEV027; (4) research_summary admits (exit 0 -> Tier 1 source_verified) while curated_catalog holds for blinded Tier 2 human_gold review (BEV010). See Architecture · 27 Rule Codes.

Real-Data Benchmarks & Integrated Showcases

Real-data multi-vendor benchmarks across 4,800 blind frontier LLM calls: BioCuration-Bench v2 reaches J = 0.987 (100% recall, 0.0% leakage) on 300 sealed PMC items; Hallucination Atlas flags 9.8% (177 of 1,800) wild claims across 100 PMC papers with 100% of quote defects caught at $0 CPU; ACMG-Triage v2 lifts P/LP vs B/LB macro-F1 from 51.4% to 69.1% and cuts critical reversals by 84.6% across 200 ClinVar variants.

Benchmark / Showcase Scale & Verification Result
BioCuration-Bench v2 300 sealed real-paper items (105 OA PMC XMLs, 1,800 blind 3-vendor calls): naked LLMs span J = 0.500–0.907 (1.9% retraction recall); full_trust_stack + gemini_4_neon_low hits J = 0.987 (100% recall, 0.0% leakage, $1.29/1k) while saving 36.3% of LLM calls. Suite
Hallucination Atlas 100 OA PMC papers · 1,800 wild claims across OpenAI, Anthropic & Google: 9.8% (177/1,800) flagged (4.4% causal inflation, 3.3% scope omission, 1.4% quote drift, 1.0% numeric drift); $0 EvidPort + BEV027 catches 100% of quote defects and 26.6% overall. Suite
ACMG-Triage v2 200 real GRCh38 ClinVar alleles across 19 genes (1,200 blind 3-vendor calls): EvidPort + BEV027 + Tavtigian lifts binary P/LP vs B/LB macro-F1 from 51.4% to 69.1%, cuts critical clinical reversals by 84.6% (2.7% to 0.4%; 0.0% at 2/3 consensus), halves Brier (0.170 to 0.082), and cuts unverified citations from 40.9% to 0.0%.
Two-Tier Reference Layer Living source_verified ledger with BEV019 retraction auto-revocation + blinded human_gold offline HTML review app and SHA-256-sealed releases across Literature, ClinVar, and ClinGen. Guide
ClinGen Validity Profile Enforces distinct admission rules for research_summary vs human-curated curated_catalog across 7 ClinGen gene–disease tiers.
Foundational v1 suites, pinned database benchmarks & offline reproduction
  • BioCuration-Bench v1 (90 sealed synthetic items): $0 local CPU full_trust_stack reaches J = 0.933 (0.48 ms/item, 4.8% leak) and 3-vendor hybrid reaches J = 0.956 (100% spec) vs J = 0.822–0.844 (16.7%–18.9% leak) for blind LLMs (details).
  • ACMG/AMP v1 (28 vignettes): EvidPort + BEV027 grounded triage reaches 28/28 (100.0%) with 0/6 false P/LP calls (Brier = 0.0013) vs 21/28–27/28 naked LLMs.
  • ClinVar Germline & VBO Canine Mapping: Tracks 5,026 ClinVar variants across pinned snapshots and blocks 160/160 injected faults + 48/48 forged sources. Replay offline: uv run --frozen python tools/reproduce.py --only extraction-test celltype-test.

Documentation & Scope

Resource Entry Point
Architecture & 27 Rules docs/ARCHITECTURE.md · docs/ENGINEERING.md
Per-Use Profiles & Drafts docs/PROFILES.md · docs/DRAFTS.md
Semantic Support (BEV027) docs/SEMANTIC_SUPPORT.md
EvidPort & Local stdio MCP docs/EVIDENCE_LIBRARY.md · docs/EVIDENCE_MCP.md
Scope, Denominators & Changelog docs/LIMITATIONS.md · CHANGELOG.md

Scope & License. Admission means a record met a declared policy for a specific research or curation use; biological interpretation still requires domain judgment, and clinical diagnosis or patient care is outside scope. Released under Apache-2.0 · Contributing · Security · Cite (CITATION.cff).

관련 프로젝트 살펴보기

불러오는 중…