Skip to content

Wire the topology solver into grammar-diffusion decoding (VSS3-03, SLM-71)#356

Merged
Tyler-R-Kendrick merged 1 commit into
mainfrom
slm-71-vss3-03-capsule-aware-exact-closure
Jul 18, 2026
Merged

Wire the topology solver into grammar-diffusion decoding (VSS3-03, SLM-71)#356
Tyler-R-Kendrick merged 1 commit into
mainfrom
slm-71-vss3-03-capsule-aware-exact-closure

Conversation

@Tyler-R-Kendrick

@Tyler-R-Kendrick Tyler-R-Kendrick commented Jul 18, 2026

Copy link
Copy Markdown
Owner

VSS3-03 (SLM-71): topology solver → grammar-diffusion decode seam

Adds a torch-free topology solver and a default-off seam that routes grammar-diffusion decoding through it. When disabled the decode path is byte-identical (only an extra telemetry key); when enabled the solver filters candidates by exact closure and records a trace — it never expands the hard domain.

What's here (8 files, +1020/−6 additive, on current main)

  • dsl/solver/topology_solver.py (NEW) — torch-free expander/verifier + monotone topology_solver_prune exact-closure.
  • dsl/solver/topology_adapter.py — additive derive_topology_state + parent_id hole metadata (main's canonical list-based TopologyEdit payload kept; the branch's dict rewrite dropped).
  • models/grammar_diffusion.py — guarded _topology_solver_survivors seam in _decode_one; disabled path byte-identical.
  • harnesses/model_build/{factory,config}.py — default-off topology_solver_* fields + a capsule-requires-verified-solver guard; old configs/checkpoints load unchanged.
  • dsl/solver/__init__.py — additive exports.
  • tests/test_models/test_grammar_diffusion_solver.py — 6 torch-gated tests (importorskip), run in CI.
  • Design doc.

Dropped the branch's wholesale re-implementations of dsl/solver/* (capsule_solver/closure/controller/decode/replay/state/support), pack.py, progspec/*, twotower.py, doc/README/MODEL_CARD clobbers, and its test-weakening of main's test_topology_adapter.py. Also did NOT apply the branch's stale reverts of design_md_dropout / surface_ar_* (VSS3-05 landed after the fork).

Verification

  • No-new-breakage vs a clean-main baseline: test_dsl failure list byte-identical (8 pre-existing, unrelated to solver/topology); test_models 0-failed both, +1 new torch-gated skip. Targeted torch-free solver/surface/topology: 143 passed. ruff / repo_policy / diff-check / compileall clean.
  • The 6 torch decode tests run in CI (torch installed).

Honesty

Wiring/mechanism increment — disabled-by-default; no model trained, no ship claim, no gate touched. Meaningful-parse out of scope.

🤖 Generated with Claude Code

@vercel

vercel Bot commented Jul 18, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
slm-training Ready Ready Preview, Comment Jul 18, 2026 7:49am

Request Review

@coderabbitai

coderabbitai Bot commented Jul 18, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@Tyler-R-Kendrick, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 22 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 722b64e0-e4c8-475f-a186-5a7c58d9a1c8

📥 Commits

Reviewing files that changed from the base of the PR and between d549706 and 93e2627.

📒 Files selected for processing (8)
  • docs/design/iter-slm71-topology-solver-decode-wiring-20260718.md
  • src/slm_training/dsl/solver/__init__.py
  • src/slm_training/dsl/solver/topology_adapter.py
  • src/slm_training/dsl/solver/topology_solver.py
  • src/slm_training/harnesses/model_build/config.py
  • src/slm_training/harnesses/model_build/factory.py
  • src/slm_training/models/grammar_diffusion.py
  • tests/test_models/test_grammar_diffusion_solver.py
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch slm-71-vss3-03-capsule-aware-exact-closure

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

…M-71)

Adds a torch-free topology solver (exact expander/verifier + monotone
exact-closure prune) and a default-off decode seam that routes
grammar-diffusion decoding through it. When disabled the decode path is
byte-identical (only an extra telemetry key); when enabled the solver
filters candidates by exact closure and records a trace, never expanding
the hard domain.

- dsl/solver/topology_solver.py: expander/verifier + topology_solver_prune.
- dsl/solver/topology_adapter.py: additive derive_topology_state +
  parent_id hole metadata (main's list-based TopologyEdit payload kept).
- models/grammar_diffusion.py: guarded _topology_solver_survivors seam in
  _decode_one; harnesses/model_build/{factory,config}.py: default-off
  topology_solver_* fields + a capsule-requires-verified-solver guard.
- tests/test_models/test_grammar_diffusion_solver.py: 6 torch-gated tests
  (importorskip) run in CI.

No-new-breakage verified against a clean-main baseline (identical
pre-existing failures; +143 torch-free passing). Disabled-by-default; old
configs/checkpoints load unchanged. Mechanism increment, no ship claim.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017NWyjZwGMUPHXZhtqQVzUJ
@Tyler-R-Kendrick
Tyler-R-Kendrick force-pushed the slm-71-vss3-03-capsule-aware-exact-closure branch from ac1b977 to 93e2627 Compare July 18, 2026 07:49
@Tyler-R-Kendrick Tyler-R-Kendrick changed the title feat(grammar-diffusion): VSS3-03 topology solver decode seam (SLM-71) Wire the topology solver into grammar-diffusion decoding (VSS3-03, SLM-71) Jul 18, 2026
@Tyler-R-Kendrick
Tyler-R-Kendrick merged commit 1b20eba into main Jul 18, 2026
4 checks passed
@Tyler-R-Kendrick
Tyler-R-Kendrick deleted the slm-71-vss3-03-capsule-aware-exact-closure branch July 18, 2026 07:56
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.

2 participants