Skip to content

Script indexes for experiments/profiling, moonshot and repair; fix two stale README statements - #126

Merged
SamMausberg merged 5 commits into
mainfrom
organize/experiment-readmes
Oct 1, 2026
Merged

SamMausberg merged 5 commits into
mainfrom
organize/experiment-readmes

Conversation

@SamMausberg

@SamMausberg SamMausberg commented Oct 1, 2026 •

Copy link
Copy Markdown
Owner

Three experiment directories had no README: experiments/profiling (24 files), experiments/moonshot (19) and experiments/repair (11 plus runs/). Someone opening them had to read each script's docstring to find out what it does and which evidence it produces. This adds a short index to each, and fixes two README statements that no longer match the repository. Markdown only.

Script indexes. Each new README has one row per file: what it does, and the evidence file it writes. Where a script has no committed output, the row says so ("pending" for runs that have not landed; for repair/gdn_state_bench.py and repair/nsys_kernels.py, why there is none: the Stage A microbenchmark was stopped without output, and the decomposition session's Nsight runs failed at launch, both as recorded in evidence/repair/README.md). The exact commands stay where they are, in the matching evidence README (and, for profiling, in run_all.sh and analyze_all.sh); the indexes point there rather than repeating them. No unmerged branch adds or edits a README in these directories. When the moonshot and repair branches add scripts, their rows go in these tables.

Stale statements.

  • experiments/head_geometry/README.md called transport "the manuscript's Section 4". That was a section of the imported manuscript; in paper/ it is the transport section (Section 5, paper/sections/transport.tex), which the line now names.
  • evidence/precision/README.md was titled "certified low-precision head (theory workstream)". It holds the exact floating-point reference tests, the Lean log and the head constants, so the title now says that (the certified-head kernel evidence will have its own directory). Its "manuscript's l_inf/l_1 family" now reads "paper's".

experiments/drafter/README.md also omits about half its files from its table. It is left to the drafter workstream, whose unmerged branch adds about twenty scripts there.

Verification:

  • Each row was checked against the script's docstring, its argument parser or the run script that calls it, and the file it names in evidence/; "pending" rows match the pending lists in evidence/profiles/README.md, the register's pending results and the absence of the file on main.
  • python scripts/check_paper_references.py: no register path missing at origin/main (no paths changed).
  • pre-commit run --files on the five files, including the host-identity guard: clean.
  • pytest -q not run for this branch: the change is Markdown only, and while timed holds ran the full suite had to wait for a shared GPU-lock slot. The queued run was cancelled after the merge, so no result is reported.

Codex comments.

  • experiments/profiling/README.md claimed analyze_all.sh analyses "whatever raw runs exist". Codex pointed out that it passes both the plain_nsys/ and mtp_nsys/ window files to bytes_model.py unconditionally, so under set -euo pipefail a missing one stops the script. Correct; fixed in 69ea66c, where the row now states the prerequisite. The script and its header comment, which makes the same claim, are left unchanged because they are the profile workstream's generator for committed evidence.
  • On the next head, Codex noted that the index said run_all.sh writes only raw reports, although its microbench, gdn and ncu steps write five files straight into evidence/profiles/, and that analyze_all.sh does not regenerate gdn_kernel_bench.json. Correct; fixed in 7dc9b57: the run_all.sh row lists the five files, the Commands paragraph warns that those steps replace the committed copies, and the analyze_all.sh row names its eleven steps and the files it does not write.
  • On 7dc9b57, Codex noted that the moonshot index said run_p4b.sh runs the P4 kernel checks; it reuses them from an earlier run after checking the engine commit. Correct; fixed in b1676f7. Rechecking the other rows against the scripts at the same time, I also corrected gdn_exact_replay_check.py (its bench mode times exact replay against the packed decode, not ReplaySSM) and added run_profiles.py's /start_profile mode.

The three directories had no README, so a reader had to open each script
to learn what it does. Each index gives one line per file: its role, the
evidence file it writes (or "pending" where the run has not produced
committed evidence), and points to the evidence README that records the
exact commands.
experiments/head_geometry/README.md called transport "the manuscript's
Section 4", a section of the imported manuscript; in paper/ it is the
transport section (Section 5). evidence/precision/README.md was titled
after the certified head and a workstream name, though it holds the exact
floating-point reference tests, the Lean log and the head constants, and
it called the paper "the manuscript".
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 1, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-01T14:48:09.131997Z b1676f7 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8747867eaf

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread experiments/profiling/README.md Outdated
| File | Role | Evidence it writes |
|---|---|---|
| `run_all.sh` | GPU steps: `microbench`, `plain`, `mtp`, `baseline`, `startprofile`, `graphtrace`, `eager`, `host`, `dflash`, `gdn`, `ncu` | raw reports in `$VP_DATA` |
| `analyze_all.sh` | Every analysis below, in order, over whatever raw runs exist | everything in `evidence/profiles/` except the microbenchmark files (`hbm_bandwidth.json`, `head_microbench*.json`, `microbench_clocks.json`) |

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Do not promise analysis of arbitrary partial runs

When only a subset of profiling steps has completed, this claim is false: analyze_all.sh always passes both plain_nsys/windows.jsonl and mtp_nsys/windows.jsonl to bytes_model.py, whose path.read_text() raises if either is absent, and set -e stops the script. A contributor using run_all.sh selectively therefore cannot analyze “whatever raw runs exist”; either document that both window files are prerequisites or make the script filter missing paths.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed: analyze_all.sh passes both plain_nsys/ and mtp_nsys/ window files to bytes_model.py unconditionally, and under set -euo pipefail a missing one stops the script. Fixed in 69ea66c: the row now says most steps skip missing runs but the bytes model needs both window files, so the script stops without the plain and mtp runs. I left the script itself (and its header comment, which makes the same claim) unchanged, since it is the profile workstream's generator for committed evidence.

bytes_model.py reads the window files of both plain_nsys/ and mtp_nsys/,
which analyze_all.sh passes unconditionally, so the script stops under
set -e unless the plain and mtp runs exist; it does not analyse an
arbitrary subset of runs. (Codex on #126.)
@SamMausberg

Copy link
Copy Markdown
Owner Author

@codex review

@SamMausberg

Copy link
Copy Markdown
Owner Author

Verdict: APPROVE (provisional: Codex is still running on 69ea66c. I will confirm or withdraw once it finishes on this head.)

Review of the exact head 69ea66c: three commits, Markdown only.

  • The indexes match the directories. Every tracked file in experiments/profiling, experiments/moonshot and experiments/repair (including runs/) has a row, and every row names a file that exists.
  • The evidence column matches main. Every evidence file named without "pending" exists in evidence/profiles, evidence/moonshot or evidence/repair, including the attribution/, windows/ and diagnostics/ directories and the stage_a_oracle* brace patterns. Every file marked pending is absent on main. The two repair "none" rows match evidence/repair/README.md.
  • The two stale-statement fixes are accurate. paper/sections/transport.tex exists. The new evidence/precision/ title describes what the directory holds. Only "manuscript's" changes to "paper's" in the body, and the numbers are untouched.
  • Codex P2 on 8747867 (the analyze_all.sh partial-run claim) is fixed in 69ea66c and has a reply. The row now states that the bytes model needs both plain_nsys/ and mtp_nsys/. The script's own header still says missing inputs are skipped, and leaving that profile generator unchanged is reasonable.
  • No overlap. No other unmerged branch touches these five files.
  • Checks. All commits are by Samuel Mausberg, with no AI lines. The hostname check is clean over the diff and the PR text, and nothing cites ~/vp-coord or notes. I did not re-run pytest (CPU quiet during bench's hold), and Markdown cannot affect it.

Merge-order note (non-blocking). #123 adds experiments/moonshot/admission_plateaus.py. Whichever of #123 and #126 merges second should add its row to experiments/moonshot/README.md.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 69ea66c69a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread experiments/profiling/README.md Outdated
Comment on lines +27 to +28
| `run_all.sh` | GPU steps: `microbench`, `plain`, `mtp`, `baseline`, `startprofile`, `graphtrace`, `eager`, `host`, `dflash`, `gdn`, `ncu` | raw reports in `$VP_DATA` |
| `analyze_all.sh` | Every analysis below, in order. Most steps skip when their raw runs are missing, but the bytes model needs the window files of both `plain_nsys/` and `mtp_nsys/`, so the script stops without the `plain` and `mtp` runs | everything in `evidence/profiles/` except the microbenchmark files (`hbm_bandwidth.json`, `head_microbench*.json`, `microbench_clocks.json`) |

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Document the tracked outputs from run_all.sh

run_all.sh does not write only raw reports under $VP_DATA: its microbench step writes hbm_bandwidth.json, head_microbench.json, and microbench_clocks.json under evidence/profiles/, gdn writes gdn_kernel_bench.json there, and ncu writes ncu_key_kernels.json. Following this index can therefore unexpectedly overwrite or create committed evidence, and the next row is also inaccurate because analyze_all.sh cannot regenerate gdn_kernel_bench.json; list these direct evidence outputs and exclude that file from analyze_all.sh's coverage.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed on both points. run_all.sh's microbench step writes hbm_bandwidth.json, head_microbench.json and microbench_clocks.json, gdn writes gdn_kernel_bench.json and ncu (via run_ncu.sh and ncu_summary.py) writes ncu_key_kernels.json, all directly into evidence/profiles/; analyze_all.sh regenerates only ncu_key_kernels.json of those. Fixed in 7dc9b57: the run_all.sh row lists the five files, the Commands paragraph warns that those steps replace committed copies, and the analyze_all.sh row names its eleven steps and excludes the directly written files and head_microbench_kernels.json.

The microbench, gdn and ncu steps write hbm_bandwidth.json,
head_microbench.json, microbench_clocks.json, gdn_kernel_bench.json and
ncu_key_kernels.json into evidence/profiles/ themselves, so running them
replaces committed files, and analyze_all.sh does not regenerate them
(except ncu_key_kernels.json). Name analyze_all.sh's steps exactly.
(Codex on #126.)
@SamMausberg

Copy link
Copy Markdown
Owner Author

@codex review

@SamMausberg

Copy link
Copy Markdown
Owner Author

Verdict: APPROVE (provisional, on 7dc9b57: Codex is still running on this head. I will confirm or withdraw once it finishes.)

The head moved from 69ea66c, which voids my earlier approval. The new commit 7dc9b57 changes only experiments/profiling/README.md, for Codex's P2 r4156679454, and it is accurate:

  • Direct evidence writes. run_microbench.sh writes hbm_bandwidth.json, head_microbench.json and microbench_clocks.json into evidence/profiles/. run_all.sh's gdn step writes gdn_kernel_bench.json (line 77), and run_ncu.sh writes ncu_key_kernels.json (line 50). The row lists exactly these five, and the new sentence warns that these steps replace committed copies.
  • analyze_all.sh's steps. In order they are attribute, collect_run, bytes_model, check_labels, layer0_share, validate_labels, host_gaps, pyspy_summary, graph_level, ncu_summary and summarize, as the row now lists. Its coverage note (regenerates ncu_key_kernels.json, but not the other direct writes or head_microbench_kernels.json) matches.
  • Codex. Both Codex threads (r4156642725, r4156679454) have replies and fixes.

Everything else is as in my review of 69ea66c.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 7dc9b57673

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread experiments/moonshot/README.md Outdated
| `gsm8k_arms.py` | GSM8K accuracy per lever stack through `bench.quality`, for the declared quality budget | pending |
| `make_long_prompts.py` | The 2,048-token prompts of P4's served test, built from a bench split | input of the P4 test |
| `run_p4_admission.sh`, `check_admission.py` | P4's admission preflight: every arm's server must run 128 requests at once during the measured phase | pending |
| `run_p4b.sh` | P4's served test in one exclusive hold: kernel checks, admission, output probe, then the paired A/B | pending |

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Do not say run_p4b reruns kernel checks

When a contributor runs run_p4b.sh, it does not execute the kernel checks described here: the script only requires the engine to equal the previously tested SHA and records that it is reusing the kernel results from run 20261001T082738Z (run_p4b.sh lines 82-89). This index therefore overstates what a fresh P4 served-test run validates; describe those checks as reused prerequisites rather than steps performed by the script.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed: run_p4b.sh checks that the engine is still at c29a91692b and reuses the kernel results of run 20261001T082738Z rather than running them. Fixed in b1676f7: the row now lists the steps the script runs (admission preflight, server output probe, the paired A/B validated by validate_p4_ab.py) and says the kernel checks are reused from an earlier run. The same commit corrects gdn_exact_replay_check.py's row (its bench mode times exact replay against the packed decode, not ReplaySSM) and adds run_profiles.py's /start_profile mode.

run_p4b.sh reuses the kernel checks of an earlier run instead of running
them (Codex on #126), and gdn_exact_replay_check.py's bench mode times the
exact replay against the packed decode, not ReplaySSM. run_profiles.py
also has a /start_profile mode.
@SamMausberg

Copy link
Copy Markdown
Owner Author

@codex review

@SamMausberg

Copy link
Copy Markdown
Owner Author

Verdict: REQUEST CHANGES (withdraws my provisional approval of 7dc9b57)

Codex finished on 7dc9b57 with one P2, r4156717855, and it is right. The run_p4b.sh row in experiments/moonshot/README.md says the script runs "kernel checks, admission, output probe, then the paired A/B". It does not run the kernel checks. At lines 82-89 it requires the engine head to equal c29a91692b and records that it reuses the kernel-level steps (kernel-check-bv32, kernel-check-bv16, kernel-bench-bv16, p7-flashinfer-verify) from run 20261001T082738Z.

Blocking: reword the row. For example: "P4's served test in one exclusive hold: checks the engine is the one the reused kernel checks (run 20261001T082738Z) ran on, then admission, output probe and the paired A/B". Then reply on the thread.

Everything else stands from my reviews of 69ea66c and 7dc9b57.

@SamMausberg

Copy link
Copy Markdown
Owner Author

Verdict: APPROVE (provisional, on b1676f7: Codex is still running on this head. I will confirm or withdraw once it finishes.)

b1676f7 fixes Codex P2 r4156717855 and has a reply. The run_p4b.sh row now lists the steps the script runs (admission preflight, server output probe, the paired A/B validated by validate_p4_ab.py) and says the kernel checks are reused, which matches lines 82-89.

The two other corrections in the commit are also accurate:

  • gdn_exact_replay_check.py's check mode compares exact replay and ReplaySSM against the packed decode, while bench_point times exact replay by ring length against fused_recurrent_gated_delta_rule_packed_decode.
  • run_profiles.py has --mode none, nsys and sglang (/start_profile).

Everything else stands from my earlier reviews.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. You're on a roll.

Reviewed commit: b1676f77c0

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@SamMausberg

Copy link
Copy Markdown
Owner Author

Verdict: APPROVE (confirmed on b1676f7)

Codex finished its review of b1676f7 with no findings ("Didn't find any major issues", a thumbs-up, and no inline comments on this head). The head is unchanged, so my approval stands.

@SamMausberg
SamMausberg merged commit e47f0e5 into main Oct 1, 2026
@SamMausberg
SamMausberg deleted the organize/experiment-readmes branch October 1, 2026 14:49
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