Skip to content

Specialization bridges (deltasignal specs/067), default add - #117

Merged
adamjohnwright merged 3 commits into
mainfrom
specialization-bridges
Oct 17, 2026
Merged

adamjohnwright merged 3 commits into
mainfrom
specialization-bridges

Conversation

@adamjohnwright

@adamjohnwright adamjohnwright commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

Implements the rule pre-registered in reactome/deltasignal#131 (specs/067), and makes add the default after adoption (Adam, 2026-10-17).

Measured (deltasignal specs/067 research.md), against canonical results/0709a1e:

arm held-out net fixed / broken p experimental worst pathway
add +59 101 / 42 8.7e-7 0 DNA Damage Bypass −7
replace +56 122 / 66 5.4e-5 0 DNA Damage Bypass −14 (fails the gate)

Curator held-out in release 89.50% → 89.81%.

Change

  • src/specialization.py: the specialization relation (component one-to-one match, set membership, stoichiometry), the precedingEvent link test, copy matching on identical member leaves, and the add / replace edge application.
  • export_nodes split into node_rows + writer (output unchanged).
  • Flag registered, validated at startup and fingerprinted. Default add; off restores the previous networks.
  • Checked against live Neo4j (Release 97): 61 linked pairs and 203 copy edges in 24 pathways, the same as the census in the spec; no pairs elsewhere.
  • Tests: tests/test_specialization.py (17). Full suite: 1222 passed; the one failure (test_main_edges_proportional_to_best_matches, MHC class I) reads a stale local output/ directory from July and fails on main as well (checked).

A canonical rebuild follows the merge.

🤖 Generated with Claude Code

adamjohnwright and others added 2 commits October 16, 2026 23:33
…DGE=off|add|replace, default off)

Join a copy of a specific complex to the copy of the generic complex it
instantiates (same member leaves), where one is one member combination of
the other and the curators order the two reactions by precedingEvent.
Traced in Signaling by PDGF: autophosphorylation makes specific p-PDGFR
complexes, every downstream step consumes the generic one, and nothing
joined them. 'replace' also drops the boundary assembly into a bridged
copy. export_nodes split into node_rows so the pass can read node identity.
Reproduces the Neo4j census exactly: 61 pairs, 203 copy edges, 24 pathways.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…ted: curator held-out +59, p 8.7e-7, experimental 0; replace failed the gate)

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@adamjohnwright
adamjohnwright marked this pull request as ready for review October 17, 2026 10:43
@adamjohnwright adamjohnwright changed the title Specialization bridges (deltasignal specs/067), default off Specialization bridges (deltasignal specs/067), default add Oct 17, 2026
…ialization_step), stubbed in the pipeline fixtures like the exports; with the default on it read Neo4j in the no-database tests

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@adamjohnwright
adamjohnwright merged commit d3ebf38 into main Oct 17, 2026
4 checks passed
@adamjohnwright
adamjohnwright deleted the specialization-bridges branch October 17, 2026 10:53
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.

1 participant