Skip to content

fix(specs): the 28 specs typecheck refused while gen emitted them (Refs #6446) - #6491

Merged
gHashTag merged 3 commits into
masterfrom
claude/t27c-gen-typecheck
Oct 5, 2026
Merged

gHashTag merged 3 commits into
masterfrom
claude/t27c-gen-typecheck

Conversation

@gHashTag

@gHashTag gHashTag commented Oct 5, 2026

Copy link
Copy Markdown
Owner

Refs #6446. This is the spec half (goal 2). The gen-path typecheck gate (goal 1) is hand-written Rust. Under the 2026-10-05 t27-only PR rule it is held on a branch and is not in this PR.

What

On master, tri misread reported 35 spec-shape pairs, 0 silent, 35 refused by typecheck, in 28 specs. gen* does not run typecheck, so all 28 still emitted Rust and C that cannot be parsed (pub variants: ,, pub GET: ,). Each one is fixed at the source:

shape in the spec becomes specs
variants : , # a | b | c (recovered as an untyped field) enum(u8) { a, b, c }, variants from the original trinity .tri eternal_monitor, autonomous_lifecycle, faculty_board, swarm_agents, batch_runner, exit_codes, namespace (ParsedCommand -> union(enum))
struct { enum : [A, B] } enum(u8) { A, B } logging, logger, color, sort, regex_advanced, async_stream, http, bson, json, msgpack, pipeline_parallel
enum_type : "enum", values : , X : Auto enum(u8) { X } conv2d_layer, dense_layer, cross_entropy_loss, feed_forward (mha_block was refused only through this import)
enum : [any]?, [K: V] maps enum_values : [str]?, entry slices PropertyEntry / ToolEntry / PermissionEntry tools/schema, tools/registry. The function bodies keep their pseudo-code map indexing, which typecheck accepts.
invariant : string (invariant is a keyword) invariant_expr : string igla/coder/pipeline, _tmp_pipeline_import
map[:]const u8, PackedBigInt> map<[]const u8, PackedBigInt> vsa/sequence_hdc

Other changes:

  • swarm_agents and autonomous_lifecycle had field : Float # text, lines, where # swallowed the comma. They now read field : Float, // text. The non-ASCII characters in those comments were removed (L3).
  • exit_codes and namespace had no tests (L4), so tests were added.
  • conv2d_layer: compiling it exposed kernel loops that indexed past the 2x2 buffer (i, j < k*k), and then result != undefined on a void call. The loops and tests are fixed and pass 2/2.

Measured on the Railway t27c lab

Measured on master c82953e plus this diff (/data/gengate), using the same commands as the lab gates.

tri misread --list, before (lab run of master 36ad787):

0 of 35 pair(s) silent, 35 refused by typecheck

after:

  generated for 1261 of 1261 spec(s)

  pairs  refused  silent
      0        0       0  rust: `pub f: ,`      field with no type
      0        0       0  rust: `pub f: 0,`     literal in type position
      0        0       0  rust: `Vec<>`         generic lost its parameter
      0        0       0  c:    `0 f;`          literal in type position
      0        0       0  rust: `pub a: Xb:Y,`  bare colon inside a type

  Nothing found, and the control above is why that reads as a result
  rather than as a silence.
  • t27c suite --corpus-only --ratchet: RATCHET CLEAN, ledger 84 / observed 84.
  • check_specs_generate.py: OK, 1327 specs, 1326 generate, 1 known-broken.
  • check_seal_currency / check_seal_coverage: none of the changed specs are listed. The 3 stale seals that remain (specs/automation/kanban-card-chat.t27, specs/runtime/process.t27 x2) are stale on master too.

Ledger and seal changes

  • docs/reports/suite_expectations.json: 25 entries removed, 109 -> 84, and max_entries follows to 84.
  • .trinity/seals/: 52 seals for the 28 changed specs, re-saved on the lab with PATH=/opt/zig:$PATH t27c seal <spec> --save and checked with tri seals sync-twins (517 already consistent, 0 written). spec_hash changed for all of them, and the gen hashes changed because the output now carries real enum declarations.

Not in this PR: the gen gate

The gate (typecheck_gate before every gen path, seal and compile-all/compile-project, the HTTP handlers, the tri misread control and a regression test) is hand-written .rs. Under the owner's 2026-10-05 rule ("no new PR may contain hand-written code in any language other than t27") it is pushed to claude/t27c-gen-typecheck-gate and no PR is opened for it.

Files

  • .t27 (hand-written spec source): the 28 specs above.
  • Tool-written data:
    • 52 .trinity/seals/*.json, written by t27c seal --save.
    • docs/reports/suite_expectations.json: 25 entries dropped by a JSON filter on the exact entries the ratchet named as fixed, and the cap lowered to match.
  • Prose: docs/now/2026-10-05-misread-specs-6446.md.
  • Hand-written non-t27 code: none.

🤖 Generated with Claude Code

@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-05 15:45:15 UTC

Summary

Status Count
Total Open PRs 50
PRs with Failing Checks 39
PRs with All Checks Green 11
READY 10
FAILING 39
PENDING 0
NO CHECKS YET 0

These columns do not partition: 10 + 39 + 0 + 0 = 49, and there are 50 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=9f2c8a4829f6 != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-05 16:01:03 UTC

Summary

Status Count
Total Open PRs 50
PRs with Failing Checks 41
PRs with All Checks Green 9
READY 8
FAILING 41
PENDING 0
NO CHECKS YET 0

These columns do not partition: 8 + 41 + 0 + 0 = 49, and there are 50 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=9f2c8a4829f6 != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

@gHashTag
gHashTag force-pushed the claude/t27c-gen-typecheck branch from 672dbf5 to 6abab22 Compare October 5, 2026 16:02
@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-05 16:03:54 UTC

Summary

Status Count
Total Open PRs 50
PRs with Failing Checks 38
PRs with All Checks Green 12
READY 9
FAILING 38
PENDING 0
NO CHECKS YET 0

These columns do not partition: 9 + 38 + 0 + 0 = 47, and there are 50 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=9f2c8a4829f6 != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

gHashTag and others added 3 commits October 5, 2026 23:12
#6446)

tri misread on master: 35 spec-shape pairs, 0 silent, 35 refused by
typecheck, in 28 specs. Each refused field is now the declaration it
described: untyped `variants` / `enum : [..]` / `values : ,` fields
become enum(u8) with the variants from the trinity .tri sources;
tools/schema and tools/registry get entry slices for their maps and
`enum_values` for the keyword-named field; the igla pipeline Contract
field `invariant` (a keyword) is `invariant_expr`; sequence_hdc gets
its map type back.

exit_codes and namespace gain tests (L4). conv2d_layer compiles now,
which exposed its kernel loops indexing past the 2x2 buffer; loops and
tests fixed (2/2 pass).

Lab (t27c-lab, master c82953e + this diff): tri misread 0 pairs,
RATCHET CLEAN 84/84, check_specs_generate OK. The 25 typecheck ledger
entries for these specs are dropped (109 -> 84, cap follows) and the 52
seals of the changed specs are re-saved with zig on PATH.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…Refs #6446)

ActivationType, Agent, AgentStatus and HealthStatus had a second
definition only because the untyped-field structs in dense_layer /
mha_block, faculty_board, swarm_agents and eternal_monitor were read as
structs. As enums they no longer conflict; ledger 88 -> 84. Written by
tri types ratchet --bless on the t27c lab (file byte-identical).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ActivationType, Agent, AgentStatus and HealthStatus no longer conflict once
their untyped variants/values sides are enum(u8). tri types classified: OK
on the Railway lab (84 names, 50 DRIFT, 34 DISTINCT).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@gHashTag
gHashTag force-pushed the claude/t27c-gen-typecheck branch from 6abab22 to 433e1c4 Compare October 5, 2026 16:12
@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-10-05 16:16:07 UTC

Summary

Status Count
Total Open PRs 50
PRs with Failing Checks 39
PRs with All Checks Green 11
READY 6
FAILING 39
PENDING 0
NO CHECKS YET 0

These columns do not partition: 6 + 39 + 0 + 0 = 45, and there are 50 open PRs. A PR is being counted twice or not at all.

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=9f2c8a4829f6 != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

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