Add Retraction Watch database integration to falsifier checks so that when hypotheses cite retracted papers as evidence, the system can flag those citations for review. Integration with the Retraction Watch API enables falsifier to detect and warn about retracted paper citations in counter-evidence PMIDs.
The falsifier (Round 5 of the debate engine) extracts falsification_results from the Falsifier persona's output, which includes counter_evidence PMIDs. Currently there's no check to verify whether those cited papers have been retracted. Retraction Watch maintains a database of retracted papers that can be queried by PMID.
retraction_check() function in scidex/forge/tools.py that queries Retraction Watch API by PMIDpost_process.py — check counter_evidence PMIDs for retraction statusretraction_status and retraction_date fields to hypothesis_falsifications table (via migration)retraction_status='retracted' in falsification recordThe Retraction Watch API (https://api.retractionwatch.com/v1/) provides paper retraction status. Since it may require authentication, fall back to the free Retraction Watch CSV data or use a PMID-based search approach.
Primary approach: Use CrossRef or PubMed to get DOI from PMID, then query Retraction Watch by DOI.
retraction_check() tool@log_tool_call
def retraction_check(pmid: str) -> dict:
"""Check if a PMID corresponds to a retracted paper via Retraction Watch.
Returns dict with:
- pmid: the input PMID
- is_retracted: bool
- retraction_date: str or None
- reason: str or None
- source: str
"""In post_process.py, when processing falsification results, iterate over counter_evidence PMIDs and call retraction_check() for each. Store retraction status in the falsification record.
Add retraction_status (TEXT) and retraction_date (TEXT) columns to hypothesis_falsifications via migration runner.
post_process.py — falsifier processingscidex/forge/tools.py — tool registrationfalsification_results from Falsifier persona outputcounter_evidence contains PMID lists used to challenge hypothesesdocs/planning/specs/t-retraction-check_spec.mdretraction_check(pmid) in scidex/forge/tools.py:_check_retractions_in_evidence() helper in post_process.py104_add_retraction_fields.py for DB schemaorchestra/task/t-retrac-retraction-database-integration$ python3 -c "from scidex.forge.tools import retraction_check; print(retraction_check('31883511'))"
{'pmid': '31883511', 'is_retracted': False, 'retraction_date': None, 'reason': 'No retraction signals found via CrossRef or PubMed', 'source': 'none'}Function returns correctly. DB schema corruption (pre-existing) prevents tool-call logging but does not affect the retraction check logic itself.