Skip to content

Ground the four unambiguous NOT_ATTEMPTED taxa, and record why four stay (#401) - #458

Merged
realmarcin merged 3 commits into
mainfrom
not-attempted-backfill-401
Aug 7, 2026
Merged

Ground the four unambiguous NOT_ATTEMPTED taxa, and record why four stay (#401)#458
realmarcin merged 3 commits into
mainfrom
not-attempted-backfill-401

Conversation

@realmarcin

Copy link
Copy Markdown
Contributor

Closes #401.

The split, taken from the issue itself

NOT_ATTEMPTED means "the tool would ground this and the KB does not" — the one status that is unambiguously outstanding work. #401 found nine. One (Desulfobacteraceae) was grounded in the meantime; four are grounded here, and four stay.

Grounded — preferred_term names the taxon its id names, majority ≥ 0.88

taxon majority
Chromobacterium violaceum s__Chromobacterium_violaceum 0.97
Methylobacterium extorquens s__Methylobacterium_extorquens 0.88
Rothia kefirresidentii KRP g__Rothia 1.0
novel multiheme-cytochrome Geobacter sp. g__Geobacter 0.948

Held on a bare majority — #396's territory

  • Colwelliag__Cognaticolwellia at 0.548: a rename decided by a coin flip. Adopting it would restate a near-tie as a fact, about a genus the record names plainly.
  • Euryarchaeotap__Methanobacteriota at 0.531: same shape.

Held on the type-species question — #374, and #377 for why it's stuck

Both Nitrospira entries → g__Nitrospira_D at 0.81, where _D is a non-type split. That is #377's pathology again — and #377 established it cannot be fixed by grounding to the type-bearing term either, because that term holds a minority of genomes while majority_fraction is bounded [0.5, 1.0] (the field means "the fraction backing the winner"). Both available answers assert something unsupported, so neither is taken.

Those two also carry preferred_terms that are informal descriptors — Nitrospira-like nitrite oxidizer, Nitrospirae core floodplain members — so grounding them would assert an identity the source may not support.

Operational note

The tool writes a block without updating gtdb_grounding_status, so each --apply is followed by --apply-status — otherwise the record contradicts itself and validate-strict rejects it. Coherence is clean, and re-applying leaves every changed record byte-identical.

The test

Pins all eight decisions, and fails if a NOT_ATTEMPTED taxon appears that is neither grounded nor listed as held — so from here the status means held, not forgotten. 9 tests. just qc green.

⚠️ CI: GitHub Actions is in major_outage per GitHub's status API — no run on this repo since 14:50 UTC. Expect no checks, as on #456 and #457.

🤖 Generated with Claude Code

realmarcin and others added 2 commits August 6, 2026 13:33
…tay (#401)

NOT_ATTEMPTED means "the tool would ground this and the KB does not" - the one
status that is unambiguously outstanding work. #401 found nine. One
(Desulfobacteraceae) was grounded in the meantime, four are grounded here, and
four remain for reasons that are not "nobody got round to it".

Grounded, each checked against the issue's own criterion - the preferred_term
names the taxon its id names, and the majority is >= 0.88:

  Chromobacterium violaceum   -> s__Chromobacterium_violaceum   0.97
  Methylobacterium extorquens -> s__Methylobacterium_extorquens 0.88
  Rothia kefirresidentii KRP  -> g__Rothia                      1.0
  novel multiheme-cytochrome Geobacter sp. -> g__Geobacter      0.948

Held on a bare majority, which is what #396 is about: Colwellia ->
g__Cognaticolwellia at 0.548, a rename decided by a coin flip, and Euryarchaeota
-> p__Methanobacteriota at 0.531.

Held on the type-species question: both Nitrospira entries -> g__Nitrospira_D at
0.81, where _D is a non-type split. That is #377's pathology again, and #377
established it cannot be fixed by grounding to the type-bearing term either -
that term holds a minority of genomes, and majority_fraction is bounded
[0.5, 1.0] because it means "the fraction backing the winner". Both available
answers assert something unsupported, so neither is taken. Those two also carry
preferred_terms that are descriptors rather than taxa.

The tool writes a block without updating gtdb_grounding_status, so each --apply
is followed by --apply-status; coherence is clean and re-applying leaves every
changed record byte-identical.

A test pins all eight decisions and fails if a NOT_ATTEMPTED taxon appears that
is neither grounded nor listed as held - so the status means held from here on,
rather than forgotten.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The review demonstrated that --apply re-grounds all four taxa this PR called
held. They were never added to WITHHELD_GROUNDINGS - the guard the repo built
for exactly this, protecting the identical 0.534 KBase ORT case - so a routine
re-run would write g__Cognaticolwellia @0.548 into the KB, which is the outcome
#401 exists to prevent. All four are on the list now, each with its reason, and
--apply skips them.

With the reason established, NOT_ATTEMPTED was also the wrong value: it means
"nothing above explains why". WITHHELD means a curator decided. Status changed
for all four, which empties NOT_ATTEMPTED entirely.

That in turn changes a guard in test_gtdb_coherence_validator: it asserted
NOT_ATTEMPTED >= 1 on the reasoning that 0 almost certainly meant mislabelling
rather than completion. It is genuinely 0 now, and the difference is that every
one of #401's nine is individually accounted for - five grounded, four withheld
with a reason apiece. The anti-mislabelling guard moves to the new test, which
fails if a NOT_ATTEMPTED taxon appears that is neither grounded nor held.

The docstring claimed a single criterion for the four groundings - "each
preferred_term names the taxon its id names" - which is false for two of them,
and is the same criterion used to hold two others. Rothia names a species while
its id is the genus, and there was no alternative: the crosswalk has no
R. kefirresidentii row. Geobacter's preferred_term is a descriptor. What
actually separates them from the held descriptors is that the held ones would
have to ground to a non-type split, so descriptor and weak target compound.

Also updated the counts in SKILL.md and the schema, and regenerated the
datamodel.

The review verified the four groundings field-for-field against the crosswalk,
reproduced them from main by --apply plus --apply-status byte-identically, and
independently confirmed the Nitrospira reasoning - the genus type species is
N. marina, not N. moscoviensis, and it maps to g__UBA8639 at 1 of 21 genomes,
so the type-bearing grounding would need majority_fraction 0.048.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@realmarcin

Copy link
Copy Markdown
Contributor Author

Review round 1 — "request changes", and rightly

The reviewer verified the grounding work field-for-field against the crosswalk and reproduced all four blocks from main by --apply + --apply-status byte-identically. Then it found that the PR's central claim was not true of the artifact.

The hold was a comment, not a hold

--apply re-grounds all four taxa this PR called held. They were never added to WITHHELD_GROUNDINGS — the guard the repo built for exactly this, and which protects the identical 0.534 KBase ORT case. A routine re-run would have written g__Cognaticolwellia @0.548 into the KB: the precise outcome #401 exists to prevent. Demonstrated, not inferred.

All four are on the list now with their reasons, and --apply skips them:

[gtdb] skipping withheld 'Colwellia' in Deepwater_Horizon_…: GTDB's majority is
g__Cognaticolwellia at 0.548 (34/62 genomes) — a rename decided by a coin flip…
[gtdb] applied 0 block(s)

And NOT_ATTEMPTED was the wrong value

It means "nothing above explains why". Once the reason is established, WITHHELD is the value — a curator decided. Changed for all four, which empties NOT_ATTEMPTED entirely.

That cascades into a guard in test_gtdb_coherence_validator, which asserted NOT_ATTEMPTED >= 1 on the reasoning that 0 almost certainly meant mislabelling rather than completion. It's genuinely 0 now, and the difference is that all nine of #401's are individually accounted for — five grounded, four withheld with a reason apiece. The anti-mislabelling guard moves to the new test, which fails if a NOT_ATTEMPTED taxon appears that is neither grounded nor held.

The docstring's criterion was false

I claimed one criterion for all four groundings — "each preferred_term names the taxon its id names" — which is false for two of them, and is the same criterion used to hold two others. Rothia names a species while its id is the genus (and there was no alternative: the crosswalk has no R. kefirresidentii row at all); Geobacter's is a descriptor. What actually separates them from the held descriptors is that the held ones would have to ground to a non-type split, so descriptor and weak target compound. Rewritten to say that.

Counts in SKILL.md and the schema updated, datamodel regenerated.

Independently confirmed by the review

The Nitrospira reasoning, with a correction I'd have got wrong: the genus type species is N. marina, not N. moscoviensis, and it maps to g__UBA8639 at 1 of 21 genomes — so the type-bearing grounding would need majority_fraction 0.048, which the [0.5, 1.0] bound rejects. (N. moscoviensis does land in _D, which is what makes the obvious framing tempting.) The hold is sound, not over-caution.

just qc green.

Round 2 verified the holds work under both --apply and --apply --refresh, and
that all four groundings reproduce byte-identically. It then found the guard
protecting them had no test: every reference to WITHHELD_GROUNDINGS outside the
script takes next(iter(...)), so deleting the four new entries left the entire
suite green. The miss would surface only after someone ran --apply and a later
test caught the resulting YAML.

tests/test_gtdb_withheld_groundings.py now carries all five and asserts its
dict and the script's name the same taxa, so a one-sided edit fails. Verified:
deleting one hold from the script fails that test.

Also fixed a sentence contradicting its own table eight lines below it -
SKILL.md still said nine items were unambiguously outstanding beside a table
this PR had updated to zero - and the 317 open items it quoted, which measures
301.

And the WITHHELD enum description, which said withholding is "usually because
the NCBITaxon id names a different organism ... fix the id and this becomes
GROUNDED". That is false for all five current instances: the #416 entry's own
reason records that its id was already corrected, and #401's four are holds on
correct ids. It now names all three reasons and says plainly that no current
instance is the id kind, so a curator does not go looking for an id to fix.

Filed #459 for the skill's stale rank breakdown and coverage percentages, which
were already wrong on main.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@realmarcin

Copy link
Copy Markdown
Contributor Author

Review round 2 — verdict: merge

Round 2 verified round 1's fixes against the tool rather than the diff: the hold works under both --apply and --apply --refresh (the latter recomputing 2–4 other blocks per file, proving the refresh path was genuinely exercised and the withheld entry excluded from it rather than from a no-op), all four groundings reproduce byte-identically from main, the distribution is exactly GROUNDED 731 / WITHHELD 5 / NOT_ATTEMPTED 0, and the datamodel regenerates identically.

The one that mattered: the new holds were themselves untested

Every reference to WITHHELD_GROUNDINGS outside the script takes next(iter(...)) — first entry only. So deleting the four new entries left the entire suite green; the miss would surface only after someone ran --apply and a later test caught the resulting YAML. That's a weaker guard than #416's, which has a dedicated apply test.

tests/test_gtdb_withheld_groundings.py now carries all five and asserts its dict and the script's name the same taxa, so a one-sided edit fails. Verified: deleting one hold from the script fails that test.

Documentation

  • SKILL.md still said "only 9 are unambiguously outstanding work" eight lines above a table this PR had updated to NOT_ATTEMPTED | 0 — the PR's own headline claim, stated two ways in one section. Also the 317 open items it quoted, which measures 301.
  • The WITHHELD enum description said withholding is "usually because the NCBITaxon id names a different organism… fix the id and this becomes GROUNDED". That is false for all five current instances — the Nitrososphaeraceae archaeon is grounded to d__Archaea when GTDB has the family at 51/51 #416 entry's own reason records that its id was already corrected, and Nine taxa the tool would ground are still NOT_ATTEMPTED, and some are thin #401's four are holds on correct ids. It now names all three reasons and says plainly that no current instance is the id kind, so a curator doesn't go hunting for an id to fix.
  • The WITHHELD_GROUNDINGS comment said "two reasons qualify"; there are three.

Filed, not fixed

#459 — the skill's rank breakdown and coverage percentages (715 blocks … 62.5%) are stale in every figure; actual is 728 and 63.9%. Already wrong on main, so it's a follow-up rather than this branch's.

just qc green · 1573 passed, 16 skipped.

@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown

Network integrity findings

Warnings only — a member with no interaction yet, or a participant matched by ontology id rather than by name, or one on a community-level interaction that resolves to no member. Reported, but does not fail the build.

Network Integrity Audit Report
================================================================================

0 error, 55 warning across 27 records with findings
Only error-severity findings fail the build.

ANME_SRB_Anaerobic_Methanotrophic_Syntrophic_Consortia
--------------------------------------------------------------------------------
  [warning] NAME_MISMATCH: Source 'ANME-1' matches no taxonomy entry by name; resolved to 'ANME-1 (anaerobic methanotrophic archaea, clade 1)' by source_id NCBITaxon:588814
  [warning] NAME_MISMATCH: Target 'Desulfofervidus' matches no taxonomy entry by name; resolved to 'Desulfofervidus (sulfate-reducing bacterial partner of ANME-1)' by target_id NCBITaxon:1902583
  [warning] NAME_MISMATCH: Source 'ANME-2a' matches no taxonomy entry by name; resolved to 'ANME-2a (anaerobic methanotrophic archaea, clade 2a)' by source_id NCBITaxon:588816
  [warning] NAME_MISMATCH: Target 'Seep-SRB1' matches no taxonomy entry by name; resolved to 'Seep-SRB1 (sulfate-reducing bacterial partner of ANME-2a)' by target_id NCBITaxon:213119
  [warning] NAME_MISMATCH: Source 'ANME-2c' matches no taxonomy entry by name; resolved to 'ANME-2c (anaerobic methanotrophic archaea, clade 2c)' by source_id NCBITaxon:3386252
  [warning] NAME_MISMATCH: Target 'Seep-SRB2' matches no taxonomy entry by name; resolved to 'Seep-SRB2 (additional sulfate-reducing bacterial partner)' by target_id NCBITaxon:213118

Total: 6 issues (0 error, 6 warning)

Aalborg_East_Full_Scale_EBPR_Community
--------------------------------------------------------------------------------
  [warning] DISCONNECTED: Taxon 'Bacteroidetes flanking community members' has no interactions
  [warning] DISCONNECTED: Taxon 'Tetrasphaera-related actinobacterial PAOs' has no interactions

Total: 2 issues (0 error, 2 warning)

Bacteroides_Methanobrevibacter_Gnotobiotic_Mouse_Mutualism
--------------------------------------------------------------------------------
  [warning] DISCONNECTED: Taxon 'Desulfovibrio piger comparator' has no interactions

Total: 1 issues (0 error, 1 warning)

BioModels_MODEL2204300001_Kefir_Community_Model
--------------------------------------------------------------------------------
  [warning] DISCONNECTED: Taxon 'Lactobacillus kefiri' has no interactions
  [warning] DISCONNECTED: Taxon 'Lactococcus lactis' has no interactions

Total: 2 issues (0 error, 2 warning)

BioModels_MODEL2405300001_Infant_Gut_HMO_SynCom
--------------------------------------------------------------------------------
  [warning] DISCONNECTED: Taxon 'Bacteroides ovatus' has no interactions
  [warning] DISCONNECTED: Taxon 'Bacteroides vulgatus' has no interactions
  [warning] DISCONNECTED: Taxon 'Bifidobacterium bifidum' has no interactions
  [warning] DISCONNECTED: Taxon 'Bifidobacterium breve' has no interactions
  [warning] DISCONNECTED: Taxon 'Blautia producta' has no interactions
  [warning] DISCONNECTED: Taxon 'Enterococcus faecalis' has no interactions
  [warning] DISCONNECTED: Taxon 'Escherichia coli K-12' has no interactions
  [warning] DISCONNECTED: Taxon 'Lacticaseibacillus rhamnosus' has no interactions
  [warning] DISCONNECTED: Taxon 'Ruminococcus gnavus' has no interactions
  [warning] DISCONNECTED: Taxon 'Streptococcus thermophilus' has no interactions

Total: 10 issues (0 error, 10 warning)

Crucian_Carp_Gut_Disease_Resistance_SynCom
--------------------------------------------------------------------------------
  [warning] UNKNOWN_TARGET: Target taxon 'Aeromonas hydrophila' not found in taxonomy section (community-level scope)

Total: 1 issues (0 error, 1 warning)

Drosophila_FiveSpecies_Gnotobiotic_Gut_Microbiota
--------------------------------------------------------------------------------
  [warning] UNKNOWN_SOURCE: Source taxon 'Drosophila five-species bacterial microbiota' not found in taxonomy section (community-level scope)

Total: 1 issues (0 error, 1 warning)

East_River_Floodplain_Core_Microbiome
--------------------------------------------------------------------------------
  [warning] UNKNOWN_SOURCE: Source taxon 'core floodplain bacteria' not found in taxonomy section (community-level scope)
  [warning] UNKNOWN_SOURCE: Source taxon 'East River floodplain bacteria' not found in taxonomy section (community-level scope)

Total: 2 issues (0 error, 2 warning)

Ensifer_YF2_Sphingobacterium_Y2_Polyethylene_Degrading_Consortium
--------------------------------------------------------------------------------
  [warning] DISCONNECTED: Taxon 'Chryseobacterium sp. MF1' has no interactions

Total: 1 issues (0 error, 1 warning)

GLBRC_UFMP_Fermentation_Community
--------------------------------------------------------------------------------
  [warning] UNKNOWN_SOURCE: Source taxon 'Olsenella (Actinobacteriota)' not found in taxonomy section (community-level scope)
  [warning] NAME_MISMATCH: Target 'Clostridium (Firmicutes)' matches no taxonomy entry by name; resolved to 'Clostridium_B sp. (MAG CLOS1)' by target_id NCBITaxon:1485

Total: 2 issues (0 error, 2 warning)

Hanford_300_Area_Unconfined_Aquifer_Community
--------------------------------------------------------------------------------
  [warning] NAME_MISMATCH: Source 'intrusion-associated Actinobacteria' matches no taxonomy entry by name; resolved to 'Actinobacteria/Actinomycetota aquifer bacteria' by source_id NCBITaxon:201174
  [warning] UNKNOWN_TARGET: Target taxon 'Hanford groundwater bacteria' not found in taxonomy section (community-level scope)
  [warning] UNKNOWN_SOURCE: Source taxon 'aquifer redox guild bacteria and archaea' not found in taxonomy section (community-level scope)

Total: 3 issues (0 error, 3 warning)

High_Solids_Switchgrass_Methanogenic_Microbiome
--------------------------------------------------------------------------------
  [warning] DISCONNECTED: Taxon 'Bacilli' has no interactions

Total: 1 issues (0 error, 1 warning)

KB1_Chlorinated_Ethene_Dechlorinating_Consortium
--------------------------------------------------------------------------------
  [warning] DISCONNECTED: Taxon 'Sporomusa spp. in KB-1' has no interactions

Total: 1 issues (0 error, 1 warning)

Legume_Rhizobia_Mars_Simulant_Symbiosis
--------------------------------------------------------------------------------
  [warning] NAME_MISMATCH: Source 'Sinorhizobium spp. (rhizobial symbionts)' matches no taxonomy entry by name; resolved to 'Sinorhizobium meliloti' by source_id NCBITaxon:382
  [warning] UNKNOWN_TARGET: Target taxon 'Medicago truncatula (host legume)' not found in taxonomy section (community-level scope)

Total: 2 issues (0 error, 2 warning)

Lunar_Martian_Simulant_PGPB_Lettuce_SynCom
--------------------------------------------------------------------------------
  [warning] UNKNOWN_TARGET: Target taxon 'Lactuca sativa (lettuce host)' not found in taxonomy section (community-level scope)
  [warning] UNKNOWN_TARGET: Target taxon 'Lactuca sativa (lettuce host)' not found in taxonomy section (community-level scope)

Total: 2 issues (0 error, 2 warning)

Lunar_Simulant_Phosphate_Solubilizing_Bacteria_Nicotiana
--------------------------------------------------------------------------------
  [warning] UNKNOWN_TARGET: Target taxon 'Nicotiana benthamiana' not found in taxonomy section (community-level scope)

Total: 1 issues (0 error, 1 warning)

Model_Lignocellulose_Formaldehyde_Crossfeeding_Community
--------------------------------------------------------------------------------
  [warning] UNKNOWN_SOURCE: Source taxon 'model lignocellulose consortium members' not found in taxonomy section (community-level scope)
  [warning] UNKNOWN_TARGET: Target taxon 'model lignocellulose consortium members' not found in taxonomy section (community-level scope)

Total: 2 issues (0 error, 2 warning)

Moss_Microbe_Complex_Regolith_Biofertilizer
--------------------------------------------------------------------------------
  [warning] UNKNOWN_SOURCE: Source taxon 'Hypnum plumaeforme (moss host)' not found in taxonomy section (community-level scope)
  [warning] UNKNOWN_TARGET: Target taxon 'Hordeum vulgare (barley model crop)' not found in taxonomy section (community-level scope)

Total: 2 issues (0 error, 2 warning)

ORNL_Clostridium_Desulfovibrio_Geobacter_Trophic_Model
--------------------------------------------------------------------------------
  [warning] UNKNOWN_TARGET: Target taxon 'Desulfovibrio vulgaris Hildenborough and Geobacter sulfurreducens' not found in taxonomy section (community-level scope)
  [warning] UNKNOWN_TARGET: Target taxon 'three-species model community' not found in taxonomy section (community-level scope)

Total: 2 issues (0 error, 2 warning)

Oak_Ridge_FRC_Uranium_Nitrate_Groundwater_Community
--------------------------------------------------------------------------------
  [warning] UNKNOWN_TARGET: Target taxon 'other groundwater bacteria' not found in taxonomy section (community-level scope)

Total: 1 issues (0 error, 1 warning)

PET_Artificial_FourSpecies_Degradation_Consortium
--------------------------------------------------------------------------------
  [warning] UNKNOWN_TARGET: Target taxon 'engineered PETase/MHETase and TPA-utilization members' not found in taxonomy section (community-level scope)

Total: 1 issues (0 error, 1 warning)

PMI_Variovorax_Thermotolerance_Collection
--------------------------------------------------------------------------------
  [warning] UNKNOWN_SOURCE: Source taxon 'Variovorax' not found in taxonomy section (community-level scope)
  [warning] UNKNOWN_TARGET: Target taxon 'Arabidopsis thaliana' not found in taxonomy section (community-level scope)

Total: 2 issues (0 error, 2 warning)

Rice_Duckweed_Bacillus_SynCom
--------------------------------------------------------------------------------
  [warning] UNKNOWN_SOURCE: Source taxon 'Bacillus SynCom' not found in taxonomy section (community-level scope)
  [warning] UNKNOWN_TARGET: Target taxon 'Rhizoctonia solani' not found in taxonomy section (community-level scope)

Total: 2 issues (0 error, 2 warning)

Saanich_Inlet_OMZ_Redox_Gradient_Community
--------------------------------------------------------------------------------
  [warning] UNKNOWN_SOURCE: Source taxon 'Saanich Inlet redox-gradient microorganisms' not found in taxonomy section (community-level scope)

Total: 1 issues (0 error, 1 warning)

Shewanella_Geobacter_Exoelectrogenic_Biofilm_Community
--------------------------------------------------------------------------------
  [warning] UNKNOWN_TARGET: Target taxon 'anode-associated biofilm community' not found in taxonomy section (community-level scope)
  [warning] UNKNOWN_TARGET: Target taxon 'anode' not found in taxonomy section (community-level scope)

Total: 2 issues (0 error, 2 warning)

Sulfide_Spring_Autotrophic_CPR_Biofilm
--------------------------------------------------------------------------------
  [warning] DISCONNECTED: Taxon 'Beggiatoa' has no interactions

Total: 1 issues (0 error, 1 warning)

Thermophilic_Lignocellulose_Composting_SynCom_Biosanitization
--------------------------------------------------------------------------------
  [warning] UNKNOWN_TARGET: Target taxon 'Pseudomonas aeruginosa' not found in taxonomy section (community-level scope)

Total: 1 issues (0 error, 1 warning)

The full report is attached to the workflow run as an artifact.

@realmarcin
realmarcin merged commit 2152408 into main Aug 7, 2026
7 checks passed
@realmarcin
realmarcin deleted the not-attempted-backfill-401 branch August 7, 2026 03:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Nine taxa the tool would ground are still NOT_ATTEMPTED, and some are thin

1 participant