- Documented the release-gated documentation contract
(
docs/documentation_contract.md, linked fromCONTRIBUTING.md): the rules the 80 release-metadata gates enforce — five-file version bumps, error-code registration before documentation, archived headers on historical design notes — previously existed only inside the test file and were discoverable only by tripping them. - Documented the one-time PyPI trusted-publisher setup in the release checklist
and allowed
workflow_dispatchreruns ofPublish; the trusted publisher had never been registered, so the tag-triggered publish workflow had never actually run to completion. - Replaced the impossible tag-publish human-review threshold with a two-track release policy: a production NLI/reranker/lexical automated review may authorize an ordinary software release, while human-reviewed benchmark claims remain blocked until real independent annotation and adjudication exist.
- Added
scripts/automated_release_review.py, which emits a digest-bound review artifact, requires zero false/weak support overcalls and full contradiction recall, verifies the citation-set aggregation fixture, and permanently recordshuman_benchmark_claim_allowed=false. - Hardened production support decisions against NLI contradiction preference, source-outage-to-fabrication escalation, excerpt/full-text scope overreach, and synthetic-label-to-human-benchmark provenance overreach.
- Made wheel smoke builds use the PEP 517
buildfrontend and declaredwheelin the development extra, so the documented package smokes also work in minimaluvenvironments that do not bundlepip. - The legacy falsification-first writing-agent prototype
(
citeguard.orchestrator,citeguard.planner,citeguard.writer,citeguard.api, the writing-benchmark buildersciteguard/benchmark/baselines.pyandciteguard/benchmark/dataset_builder.py, plusscripts/run_agent.pyandscripts/evaluate.py) moved out of the published package to the repo-rootlegacy/directory; it now exists only in source checkouts. Theapioptional extra (FastAPI/uvicorn) was removed with it, and wheel/sdist gates now reject any writing-agent prototype path. Live support-eval helpers (metrics, calibration, experiment artifacts) stay inciteguard.benchmark. - BEHAVIOR CHANGE:
verify_citation_toolno longer accepts claim-support inputs (abstract,evidence_chunks,evidence_text,full_text,full_text_file); those belong to the claim-support tools. Existence and metadata verification never used them.
- Identifier-authority resolution: when a citation carries a DOI/arXiv id, the
id is now resolved strictly at its home source (Crossref/arXiv) first, with
one retry. A hit is definitive and beats any title match; a failed authority
lookup downgrades the verdict to
ambiguouswithoutage_limited=trueinstead of risking a title-onlymetadata_mismatch. Results expose the newidentifier_lookupfield (kind/value/source/status). - Polluted-record defense: same-title candidates that disagree on publication
year across sources, or best matches that look like hijacked/mirror records
(greylisted DOI prefixes via
CITEGUARD_SUSPECT_DOI_PREFIXES, implausible citation counts on brand-new years), now degrade toambiguousinstead of a confident mismatch, and never produce asuggested_citation. - arXiv ids are compared by their version-less base id, so a cited
1706.03762matches a source record carrying1706.03762v7. - Fixed multi-source search ranking: raw source relevance scores (unbounded, e.g. OpenAlex values in the thousands) are now squashed to 0-1 so they can no longer dominate title similarity.
- Added a golden-case live canary (
scripts/canary_live.py+data/eval/canary_golden.json) with a nightly GitHub Actions run that opens an issue on verdict drift. - Multi-source queries now fan out concurrently within a total time budget
(
CITEGUARD_SOURCE_BUDGET, default 8 seconds); sources that exceed the budget are recorded asbudget_exceededfailures instead of blocking the whole verification. - BEHAVIOR CHANGE:
build_live_metadata_sourceno longer enables landing-page evidence harvesting by default (opt in viaharvest_remote_evidence=True/CITEGUARD_REMOTE_EVIDENCE=1), aligning the library default with the MCP runtime. - Added opt-in open-access full-text support (
CITEGUARD_OA_FULLTEXT=1): claim-support checks can now fetch the paper body from source-declared OA locations (with an official arXiv PDF fallback) and judge claims atevidence_scope=full_text; gated hosts stay blocked and paywalls are never bypassed. Fetch outcomes are reported asresolution.oa_fulltextand a failed fetch never changes a verdict. - Added a tag-triggered PyPI trusted-publishing workflow that builds, tests, publishes, and attaches artifacts to the GitHub release automatically.
- Added GB/T 7714 (Chinese national standard) reference parsing:
[J]/[M]/[C]/[D]style references are now parsed into structured title/authors/venue fields in free-text parsing and file extraction, making Chinese bibliographies verifiable. - Crossref search now skips predominantly-CJK queries (its bibliographic search cannot match them); DOI lookups are unaffected.
- Added a registrar-agnostic DOI existence probe:
not_foundresults with a DOI now includedoi_registrationfrom the global doi.org Handle registry, so papers whose DOIs live outside open sources (e.g. China DOI/ISTIC) can be confirmed as real without ever escalating missing metadata to fabrication. Disable withCITEGUARD_DOI_REGISTRY=0; skipped in offline fixture mode. - Removed the legacy root-package compatibility shims and
setup.py; the project now builds exclusively frompyproject.toml(PEP 517) and both source checkouts and release artifacts expose only theciteguard.*surface. - Modernized the sdist install smoke to build with
python -m buildinstead of the removedsetup.py sdistpath. - Made Chinese the primary
README.mdwith a full English companion inREADME.en.md; release gates now check the bilingual documentation set. - Renamed the PyPI distribution to
citationguard(theciteguardname on PyPI belongs to an unrelated project). The import package staysciteguardand theciteguard/citeguard-mcpconsole commands are unchanged; README warnings explain the mapping. - Added ruff linting (CI job + config) and relaxed the
[models]extra pins to compatible ranges instead of exact versions. - Added incremental mypy type checking to CI: four core modules were cleaned
up and the remaining typed debt is tracked as an explicit override list in
pyproject.toml. - Fixed
--review-queue-onlyoutput missing the documentedrelease_summaryblock. - Added public
citeguard.cliandciteguard.mcp.serverentry points. - Added JSONL support for
citeguard auditandciteguard support-audit. - Added
examples/citations.jsonlplus release-gated audit JSONL smoke coverage. - Added
citeguard extractplus directciteguard auditsupport for Markdown, LaTeX/BibTeX, DOCX, and plain text reference extraction. - Added
citeguard support-audit refs.md --claim "..."so one claim can be checked against citations extracted from Markdown, LaTeX/BibTeX, DOCX, or plain text reference files. - Added release-gated
support-audit refs.md --claim "..." --with-counterevidencecoverage so extracted reference-file audits can attach counter-evidence review leads while preserving risk-sorted citation indexes. - Added release-gated
support-set --with-counterevidencecoverage so multi-citation claim checks keep aggregate review leads and safe interpretation wording in offline package gates. - Added MCP helper and stdio smoke coverage for
check_claim_support_set_tool(include_counterevidence=true)so agent clients verify one-claim/multiple-citation counter-evidence review leads end to end. - Added post-publish smoke
planned_checksplus public console entry point validation forciteguardandciteguard-mcpso PyPI/TestPyPI release rehearsals protect the installed command surface. - Added optional post-publish MCP stdio smoke coverage that starts the installed
citeguard-mcpentry point against an offline fixture after installing themcpextra from PyPI/TestPyPI. - Extended post-publish MCP stdio smoke coverage to call
check_claim_support_set_tooland verifysupport_mode_details, including conservative no-unstated-full-text support policy fields, from the installed package. - Made post-publish smoke configuration and venv setup failures machine-readable,
including
mcp_stdio_smoke_requires_mcp_extrawhen--mcp-stdio-smokeis used without--extra mcp. - Made post-publish smoke run installed-package checks from an isolated
smoke-cwdwithPYTHONPATHremoved so repository-local sources cannot hide a failed PyPI/TestPyPI install. - Added post-publish smoke validation for
--require-extra-import, accepting only dotted Python module names and reportinginvalid_required_extra_importbefore any install runs. - Added local wheel MCP stdio package smoke coverage so
scripts/smoke_package.py --install-mode wheel --extra mcp --with-deps --mcp-stdio-smokeinstalls the built wheel and drives the installedciteguard-mcpentry point through an offline MCP client before release. - Added an agent-skill example for
audit_claim_support_toolwith bothinclude_counterevidence=trueandhigh_risk_only=true, including safe wording for omitted-row summaries and review leads. - Added batch
risk_ranking, recommendations, and--high-risk-onlyfiltering for citation and claim-support audits. - Added batch
review_summary.action_queuesso agents can route identity, metadata, evidence, source retry, rewrite/replace, and keep decisions without parsing prose. - Added
filtered.returned_indexesandfiltered.omitted_indexesto--high-risk-only/ MCPhigh_risk_onlybatch outputs for traceability back to original inputs. - Added
filtered.omitted_review_summaryto high-risk filtered batch outputs so agents can summarize hidden low/medium-risk queues without expanding every row. - Added
citeguard support-setandcheck_claim_support_set_toolfor abstract-level checks of one claim against multiple cited papers. - Added machine-readable
evidence_scopeto claim-support outputs so agents can distinguish title/abstract/metadata/full-text evidence. - Expanded the synthetic support eval seed set with provenance fields, hard negatives, contradiction examples, supported precision/recall/F1, abstention rate, false-support rate, confusion matrices, high-risk support error buckets, optional case-type/evidence-scope breakdown reports, and title/metadata/full-text scope examples.
- Added a hard-negative support seed for real citation-auditing papers that do not support overstrong deployed-agent hallucination-elimination claims.
- Added offline MCP stdio smoke coverage through
scripts/smoke_mcp.py. - Added
CITEGUARD_FIXTURE_CITATIONSfor deterministic offline citation fixtures. - Added cache schema versioning plus
citeguard cache inspectandciteguard cache clear. - Added
citeguard cache exportfor deterministic offline replay fixtures. - Added cache export provenance for source, query, timestamp, operation, and raw match score.
- Made deterministic cache exports strip timestamp-only manifest fields as well as record provenance so full JSON payloads are reproducible.
- Added source-level readiness reporting in
citeguard status/citeguard_status_tool. - Added summary-level source health failure counts and failure details for agent retry/configuration decisions.
- Added source health
failure_kind_countsandfailure_kind_sourcessummaries so agents can branch on timeout, rate-limit, HTTP, and network failure modes without parsing per-source detail lists. - Added short HTTP retries for transient scholarly source failures plus
CITEGUARD_HTTP_RETRIESandCITEGUARD_HTTP_RETRY_BACKOFFstatus fields. - Added machine-readable HTTP/source failure diagnostics for timeouts, rate
limits, HTTP errors, and network failures, surfaced through verification
result
source_failure_details. - Added stable error-code documentation and CLI/MCP setup references.
- Added a public stable error-code registry in
citeguard.errors, with tests keeping the registry and docs synchronized. - Added structured
file_errordetails for cache export output-path failures, includingdetails.field=outputanddetails.cache_command=export. - Added
details.field,details.expected, anddetails.receivedto MCP batch shape errors so agents can repair malformedcitations/itemspayloads without parsing prose, and extended the MCP stdio smoke to verify those details through the real server transport. - Added support-labeling guidelines for future human-reviewed claim-support benchmark expansion.
- Added support-label sidecar maturity diagnostics for dual-label disagreement pairs and supported-label disagreement case ids.
- Added a release gate option for blocking benchmark claims when supported-label disagreements remain unresolved.
- Added high-risk support-label review coverage metrics and a
--min-high-risk-reviewedsidecar gate for release readiness checks. - Added support-eval validation for high-risk
testsplit coverage so final support reports cannot omit weak-support, hard-negative, contradiction, or full-text-required boundaries. - Added grouped
false_support_case_idsandweak_false_support_case_idsin support false-overcall analysis for split/case-type/evidence-scope triage. - Added
false_support_analysis.risk_slices/top_risk_sliceand baseline comparisonfalse_support_risk_slicesso contradicted, hard-negative, full-text-boundary, test-split, and non-English support overcalls have a stable machine-readable review priority. - Added a default release-gate
support_baseline_comparisoncontract so baseline rows keepfalse_support_risk_slices/top_false_support_risk_slicewhenever support overcalls are present. - Added compact
false_support_analysistoscripts/eval_support.py --review-queue-onlyand the release-gatesupport_review_queuecontract so agent triage payloads expose supported-overcall priority slices without expanding the full per-case report. - Added compact false-support overcall triage fields to experiment
manifest.jsonsummaries so saved support eval and baseline runs expose the top risk slice without loading full result payloads. - Extended the release gate to verify support review-queue and baseline artifact manifest summaries keep false-support overcall counts, backend, and top risk-slice fields.
- Updated the packaged
citeguard-verifyskill examples to readfalse_support_analysis.risk_slices/top_risk_sliceduring support benchmark triage and to treat contradicted supported-overcalls as release-blocking review items. - Documented support-eval review-queue and baseline-comparison JSON contracts in
the CLI reference, including compact
false_support_analysisandtop_false_support_risk_slicefields for agent triage. - Added support-eval
review_queueplus baseline comparisonreview_queue_case_ids/critical_review_case_idsso agents and maintainers can inspect the highest-risk support failures first. - Added
quality_gate.review_queue_case_idsandquality_gate.critical_review_case_idsto support-eval gate failures. - Added
scripts/eval_support.py --review-queue-onlyfor compact support-failure triage payloads. - Added a default
support_review_queuestep to the release package gate so compact support triage output is checked before release. - Added
prepare_support_label_sidecar.py --from-review-queueso support eval failure queues can be converted directly into blinded human annotation packets without exposing gold labels or backend predictions. - Added a release-gate smoke for review-queue annotation packets so release summaries prove the blinded packet path works and does not expose hidden labels or backend predictions.
- Added support-set policy coverage to baseline comparison artifacts and release gate manifest checks, keeping citation-set aggregation boundaries visible beside evidence-level false-support triage.
- Added support-label audit
policy_boundary_unreviewedoutput and a release-gated policy-boundary annotation packet smoke for weak citation-set cases that must remain tentative instead of being upgraded to full support. - Added support-label audit
full_text_required_unreviewedoutput and a release-gated full-text-boundary annotation packet smoke so abstract-level support gaps can be reviewed separately before full-text readiness claims. - Added support-label audit gates
--fail-on-full-text-required-unreviewedand--fail-on-policy-boundary-unreviewedso release checks can block premature full-text or multi-citation support readiness claims. - Added label-source and source-locator provenance metrics to support sidecar validation and the release gate, keeping synthetic seed coverage distinct from human-reviewed benchmark evidence.
- Added support-label provenance summaries to experiment
manifest.jsonartifacts so release tables can show sidecar maturity without opening the full result payload. - Extended the support-baseline release gate to validate those manifest
support_label_*summaries againstlabel_sidecar_gate.metrics. - Added agent-skill guidance and release-gate checks for policy-boundary annotation packets, keeping multiple weak citations tentative until reviewed.
- Added an agent-skill full-text-boundary annotation packet example so agents keep abstract-only support gaps as insufficient evidence until review.
- Added HTTP attempt/retry diagnostics to live-source failure details and bumped the source-health schema so agents can see when CiteGuard already exhausted its short retry policy.
- Added a counter-evidence safety release gate so retrieval candidates remain review leads, not contradiction verdicts or silent rewrite permission.
- Added a release-gate contract that keeps the legacy
srcpackage limited to thinciteguard.*compatibility shims. - Added a default release-gate public API contract so README, tests, scripts,
user-facing docs, and
citeguard.*package code stay on stable public imports instead of the legacy namespace. - Added a release-gate cache replay fixture smoke that exports deterministic cache fixtures twice and verifies offline replay without timestamp-only provenance leaks.
- Added a default release-gate error-code contract so
citeguard.errors,docs/error_codes.md, recovery guidance,next_actionmappings, and sample payload shape stay synchronized for agents. - Extended the shared error contract with machine-readable
error.retryableanderror.categoryfields, and updated the agent skill to branch on those fields instead of parsing natural-language error messages. - Added a default release-gate CLI error contract smoke that runs real
python -m citeguardfailures for missing citation input, missing audit files, and invalid JSONL support-audit input, then verifies stableschema_version,error.code,error.recovery,error.next_action, anddetailsfields. - Added a default release-gate source-outage safety contract so all-source
failures stay low-confidence,
outage_limitednot_foundresults withnext_action=retry_or_check_source_health, while source-health summaries keepsources_checked,sources_responded,sources_failed, and timeout failure kinds separate for agents. - Added a default release-gate live-source health contract so OpenAlex, Crossref, arXiv, and Semantic Scholar aliases, checks, responded/failed source lists, timeout/rate-limit failure-kind summaries, and Semantic Scholar API-key status stay stable for agent integrations.
- Extended the security/compliance release gate to include Semantic Scholar source-health polite-access state, keeping optional API-key configuration separate from OpenAlex/Crossref mailto requirements.
- Added a default release-gate security/compliance contract so docs, polite
CITEGUARD_MAILTOstatus, fixture bypass behavior, gated-source host blocks, and disabled-by-default remote evidence policy stay machine-checkable. - Added a default release-gate agent skill contract so packaged
citeguard-verifyinstructions keep proactive triggers, forbidden behaviors, Codex/Claude Code/Cursor setup notes, response templates, MCP payload examples, and safe wording examples for not-found/source-outage cases. - Added a default release-gate batch workflow examples smoke that runs packaged
extract,audit,support-audit, JSONL,support-set, and--high-risk-onlyexamples against an offline fixture, then checks summaries, action queues, filtered index traceability, and citation-set result shape. - Added citation-audit
risk_rankingrepair hints (mismatched_fields,suggested_citation, and canonical identifiers) so batch agents can present metadata corrections directly from the risk-sorted review queue. - Added support-audit
risk_rankingprovenance fields (support_confidence,support_engine,resolution_verdict, resolved title/year, and evidence source name/field/URL) so claim-support batch rows can be displayed without expanding full result payloads or inferring the source from field-name prefixes. - Added citation-set aggregate provenance fields (
evidence_scopes,evidence_source_names, andevidence_source_fields) so support-set and support-audit rows can show set-level evidence provenance without expanding every child citation result. - Added a default release-gate benchmark claim safety contract so
release-facing docs cannot describe the synthetic support seed set as a
human-reviewed benchmark while label provenance still reports
human_reviewed: 0. - Added a default release-gate MCP stdio smoke contract so
scripts/smoke_mcp.pymust keep initialize/list-tools, offline fixture verification, batch high-risk filtering, source-outage safety, and structured error coverage. - Added language coverage and
by_languagesupport-eval reporting so English and Chinese false-support or missed-contradiction risks can be triaged separately. - Added language breakdowns to support-label
high_risk_reviewsidecar validation so reviewed and unreviewed high-risk benchmark cases can be audited by language before release claims. - Added
--min-high-risk-reviewed-by-languagesidecar gates for release checks that require human review coverage for specific benchmark languages. - Added a default
support_label_sidecar_gatestep to the consolidated release package gate so package releases also validate support-label provenance. - Made the release gate record structured support-label gate thresholds, metrics, and failures instead of requiring agents to parse stdout tails.
- Added
prepare_support_label_sidecar.py --limit-per-languageand--limit-per-case-type/--limit-per-evidence-scopefor balanced high-risk annotation batches. - Added
prepare_support_label_sidecar.py --unreviewed-onlyso reviewer packets can skip cases that already have human-review provenance. - Added
prepare_support_label_sidecar.py --review-statusfor second-reviewer and status-specific annotation packets. - Added annotation-packet
packet_summarycoverage metadata, includingcase_count_by_review_status, for review-batch provenance. - Added support-label audit
recommended_packetsso maintainers and agents can turn review-readiness gaps into reviewer-packet commands without parsing prose. - Added a release-gate smoke that generates the balanced support-label
recommended_packetsannotation packet and checks review-status provenance without leaking hidden gold, adjudicated, or prediction fields. - Added
review_phaseandpacket_purposemetadata to support-label annotation packets generated from recommended review-plan commands. - Added deterministic annotation-packet
packet_idvalues for reproducible reviewer-batch archives. - Added
merge_report.source_packet_idsto preserve reviewer-batch provenance after annotation-packet merges. - Added
source_packet_metadatato annotation-packet merge and adjudication reports so review phase and packet purpose survive conflict resolution. - Added
merge_report.adjudication_queuewith reviewer rationales and blank adjudication templates for unresolved annotation disagreements. - Added source packet ids and packet case indexes to annotation conflict examples so adjudication can trace disagreements back to reviewer batches.
- Added
source_packet_idsto adjudication templates, reports, and sidecar notes so resolved disagreements preserve reviewer-batch provenance. - Added high-risk case-count-by-language metrics to support-label gates so release checks can report reviewed and unreviewed language coverage in one place.
- Added high-risk support-label review cross tables by language and case type so manifests and release reports can assign contradiction, hard-negative, and full-text-boundary review gaps without re-parsing sidecar rows.
- Added language-specific high-risk audit failures for support-label sidecar readiness checks, so reviewer assignment can block on unreviewed Chinese or other language-specific high-risk cases.
- Expanded the synthetic support eval seed set to 48 evidence-level cases with additional high-risk hard-negative, contradiction, and full-text-required boundaries for benchmark-provenance overclaims, source-outage fabrication inferences, abstract-only eligibility claims, simulated-review causal overclaims, reviewer-replacement overclaims, multi-paper weak-evidence over-synthesis, model-availability-as-support overclaims, supplemental-material full-text boundaries, and Semantic Scholar rate-limit non-existence overclaims. The latest contradiction case keeps counter-evidence search leads as review signals rather than final contradiction verdicts.
- Expanded citation-set support policy coverage to 6 citation-set policy cases, including a Chinese citation-set weak aggregation boundary and a source-limited citation-set fabrication boundary.
- Added Chinese source-outage/not-found safety benchmark cases covering unsafe fabrication-confidence overclaims, Crossref timeout hard negatives, and rate-limit/not-found contradiction examples.
- Expanded the CiteGuard agent skill examples with high-risk-only batch audit payloads and structured MCP shape-error repair guidance for agents.
- Added non-gold
review_focushints to support-label annotation packets so reviewers know which support boundary to inspect without seeing gold labels, adjudicated labels, orlabel_notes. - Added a
source_outage_safetycounter-evidence query role andsource_outage_safety_cuecandidate signal for claims that overinterpret source outages, timeouts, ornot_foundas fabrication evidence. - Extended source-outage safety counter-evidence probes to Chinese source-outage/not-found overclaims while keeping the same stable role and signal fields.
- Expanded the CiteGuard agent skill with client-specific MCP setup notes, structured-error recovery guidance, and safe wording examples for ambiguous, metadata-mismatch, not-found, outage, and claim-support results.
- Added an agent-skill scenario routing table for bibliographies, generated related-work citations, single/multi-citation claim-support checks, ambiguity, metadata mismatches, and source-limited results.
- Moved detailed agent-skill MCP payload and wording examples into
skills/citeguard-verify/references/examples.mdso the main skill stays concise while examples remain packaged. - Added
skills/citeguard-verify/agents/openai.yamlwith display metadata, default prompt, and the CiteGuard MCP stdio dependency for Codex-style skill surfaces. - Added a reusable agent response template for batch audit summaries, action queues, high-risk filtering indexes, evidence-scope limits, and next steps.
- Added release metadata guard tests for console scripts, distribution manifests,
and public
citeguard.*import hygiene. - Added a legacy import deprecation signal plus public API migration notes so
new code can standardize on
citeguard.*while older imports keep working. - Converted legacy retrieval and verification package entrypoints into thin
public
citeguard.*shims so compatibility imports share the stable public export lists. - Refreshed the roadmap around the current agent-auditor package status, implemented MCP/batch/cache/source-health foundations, and remaining benchmark/full-text/release gaps.
- Added example batch input files for citation and claim-support audits.