agent harness: sim shellHook fix, sim-probe/flag-where/arm-history, AGENT-ONBOARDING #204
No reviewers
Labels
No labels
cards:go
hermes-approved
human-approved
human-approved
iter
0
iter
1
iter
2
iter
3
prio:high
prio:low
prio:med
priority/high
state
blocked
state
doing
state
done
state
review
state
todo
x280
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
bitpartner/tt-stack!204
Loading…
Reference in a new issue
No description provided.
Delete branch "agent-harness"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
New agents (Muse via opencode, and our own subagents) lost turns on sim-env noise and silent slot waits. verify-3 also counted 12 WRONG review findings. Most missed a guard, reset, record or deliberate arm deletion that existed elsewhere. The rest held draft-depth levers to the per-step bar and the accept guard. This PR is docs and tooling only: no arm, patch or kernel changes, so it does not trigger the cards job.
Root cause fixed (nix/sim/flake.nix shellHook). The hook ran python3 while a desktop
LD_LIBRARY_PATHleaked expat 2.7.1. That printed the pyexpat ImportError, leftTT_METAL_HOMEempty and printed "ttnn: NOT importable", although the env was fine.scripts/sim-run.sh:45only unsets the variable later. The hook now unsets it first. The OK line now comes from the hook's own discovery, because a second import in the hook fails on EROFS (tracy mkdir), which sim-run.sh's overlay already handles. Verified withnix develop ./nix/sim#runtime --command bash -c 'echo $TT_METAL_HOME': the path is set and there is no ImportError.New scripts (shellcheck clean; CI already lints
scripts/*.sh):scripts/sim-probe.sh <probe.py> [args] [--out X]waiting for ttsim slot/running/done rc=Nlines, plus the probe's result lines.$TMPDIR(when it is not under /tmp) or in the gitignored.tmp/sim-probe/.sim_kv_update_fold.py --Ts 1 --Bs 1 --only edge_T1_B1gave all_ok in 34 s. A fake busy slot printed the waiting heartbeat, and the no-wrapper fallback warned.scripts/flag-where.sh [--prefix] FLAG: definitions, uses of the bound constant (that is where the guards live), arm settings, switchclass class, LEVERS lines and LEDGER lines with their entry ID. No.pycnoise.scripts/arm-history.sh <fragment>:git log --all --diff-filter=ADRover the matching arms, then the bench/runs records, then PRs whose title or body mentions the fragment. It reproduces #194's odoc case: added inea95224f, deleted inb91ba951.docs/AGENT-ONBOARDING.md (161 lines, commands and facts):
-dx-b8k3: +2.02% per token, -2.85% per step, B8 -8.77/-8.51%, accept -5.66%. Shipped-b8k3-cph48: +2.25%, -2.92%, B8 -9.39/-8.29%, accept -5.24%. #203 is noted as open;AGENTS.md gains one pointer line. LEDGER.md gains a 9-line "Current state" box: CONTROL, the last 3 ships, the last 3 kills or parks, and the open PRs. It is refreshed at each ship.
Checks: nixfmt --check on the CI file set passes. shellcheck on the CI script set passes.
check-cited-records.pyOK. The ttx lint and dead-lever unit tests pass (ttx itself is untouched).Follow-ups (out of scope):
L-xxxx) in LEVERS.md, with lint and citation support. Row-number citations break on every edit.docs/FLAG-INDEX.md.bench/probes/sim_common.py.🤖 Generated with Claude Code
verdict: approve
tier: T1 — host-local docs + shell scripts + one nix shellHook change; no arm, patch, kernel, or CI-gate edits. Docs/tooling only, does not trigger the cards job.
rationale: Verified black-box against the description and the diff. Diff direction is correct (merge-base = master
e59447c, head =4e577b1on agent-harness). No secrets, no code-exec / injection / shell-interpolation patterns in any new file. The shellHook fix is correct:unset LD_LIBRARY_PATHnow runs before the ttnn discovery so the pyexpat ImportError goes away, and the OK line is keyed off the discovery result rather than a secondimport ttnnthat would fail on EROFS (handled later by sim-run.sh's overlay). Three new scripts passbash -n. CI run #7320 is waiting on the approval gate; head is not behind master.Cards skipped
PR #204
91ce5f02f4431316255d5d0b0eaf05f307cc8257(refs/pull/204/head) does not touch card-facing paths (bench/arms/,patches/, kernel/op sources, or.forgejo/workflows/). No card boot. Build out:/nix/store/hbb3j0xxx0pqf760i3p54q54gzgmzpc9-vm-test-run-tenstorrent-serving.agent-gateway closeout (merged): cleared
agent:*labels.Hermes kanban card (if any) is left for Hermes to archive/complete.