Repository navigation
feat(profiling): lifecycle template, profiling-summary@3 coverage grid, samplers 0C paths, Pulse/Insight read prose (likelihood-lifecycle 0E) - #536
Merged
Conversation
…d, samplers 0C paths, Pulse/Insight read prose (likelihood-lifecycle 0E) (a) skills/profiling/lifecycle.md: the L0-L7 lifecycle as a phase-prompt template (one placeholder set; one fenced prompt block per step with owning repos, Brain door, human gate, witness and a full Mind header). Linked from the profiling skill, its command page and the conductor AGENTS.md. A test renders it for imaging/delaunay and judges the prompts with intake's own census. (b) Profiling conductor: a published profiling-summary@3 catalogue switches `campaign` to the lifecycle grid (likelihood x class x measurement; cells current / stale / superseded / missing), reads the mirrored results tree, refuses setup_ids off the R1 grammar (SetupIdError), never counts local_* hosts as current, reports class as declared. v2/absent catalogue: unchanged (live dry-run JSON byte-identical). (c) Samplers faculty: mature tier reads autolens_inference's scripts/<dataset_type>/<variant>/samplers/ (path fallback; old searches/ shape kept for autofit_inference); validation/ leaves listed as their own tier. (d) Prose: optimal+current default reads, optimal is a Pulse designation, walltime-validation@1 / lens-walltime is Pulse's, Insight records setup_mode: auto with setup_resolved, Pulse selector order. Closes #535 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Phase 0, sub-issue 0E of the
likelihood-lifecycleepic. This is the Brain side of the lifecycle. PyAutoBrain is the only repo changed: no autolens_profiling, autolens_inference, Pulse, Insight or Mind edits, and nothing under.github/or the token files (#534 is live on another branch).What and why
(a)
skills/profiling/lifecycle.md: the report §3.9 sequence L0 register → L1 figures → L2 profile → L3 designate → L4 validate → L5 gradient → L6 samplers → L7 close, written as a phase-prompt template.prompt <draft path>block. Each block holds the full Mind header (Type,Target,Repos,Themes,Difficulty,Autonomy,Priority,Status,Consequence,Witness,Review-minutes,Unattended,Epic: lifecycle-<dataset_type>-<variant>, integerPhase0–7,Blocked-by) followed by a short body.<dataset_type>,<variant>,<instrument>,<regime>and<trigger>.reoptimisedenters at L2 and drops L2'sBlocked-by.skills/profiling/SKILL.md,profiling.mdand the conductorAGENTS.md.tests/test_profiling_lifecycle_template.pyrenders the template forimaging/delaunay, files the prompts into a temporary Mind and runs intake's owncensus(), which is the same checkpyauto-brain intake censusapplies, so no header rule is restated. It asserts:Type/Targetmatches its folder;reoptimised, rendering starts at L2 with L2 unblocked.(b) Profiling conductor (
_catalogue.py,_profiling.py)read_lifecycle()detects a publisheddashboard/catalogue.jsonwithprofiling-summary@3. When one is present,campaignreports coverage per likelihood × class × measurement overplanned_cells. Each cell iscurrent,stale,supersededormissing. "Stale" means the current record'srelease_pinis behind the catalogue's pin; that pin is the envelope's own, otherwise the newest pin among the records, and the output says which.results/<dataset_type>/<variant>/<instrument>/<setup_id>/<host_class>/when it exists: per cell it reports the tree as present, directory only or absent, and it lists tree directories that have no catalogue row.setup_idby the R1 grammar and refuses violations with a namedSetupIdError. That covers records, planned cells and tree directory names, and includes an explicit_na.local_*hosts are flagged and never count as current (R7).--partition=raland A100 cells togpuwith--gres, with the 3600 s cap. It only plans and never runs anything.read_cataloguenow also acceptsscript_routesfrom a v3 published catalogue.(c) Samplers faculty
scripts/<dataset_type>/<variant>/samplers/<sampler>.py(orsamplers/<sampler>/<leaf>.py) through the path-shape fallback. autofit_inference keeps itssearches/<sampler>/<model_type>.pyshape.validation/leaves get their own tier (TIER_LENS_VALIDATION) and are never sampler cells.(d) Prose (
skills/profiling/profiling.md, conductorAGENTS.md,skills/sampler_pipeline/{SKILL,reference}.md, samplersAGENTS.md)class: optimal+status: currentunless asked otherwise.optimalis always a Pulsedesignationdecision.walltime-validation@1, instancelens-walltime, producer autolens_inference), never Insight's.setup_mode: auto, withsetup_resolvedas provenance.Live dry-run proof (canonical checkouts)
bin/pyauto-brain profiling campaign --json: the before and after output is byte-identical (sha256be73b898…0714both times): grid_cells 22, runs_done 23, runs_unusable 4, runs_missing 17. The--tier a100 --jsonoutput, the--axis compile --jsonoutput and the human-readable text output are also byte-identical before and after.bin/pyauto-brain samplers:delaunay/rectangularsampler cells (emcee, nautilus, nuts, smc) from the 0C tree.imaging/{delaunay,rectangular}/baseline_slam.tests/fixtures/setup_summary_v3.json, read through the conductor (in a scratch copy), gives 4 current and 1 missing (euclid) of 5 planned cells, plus 1 superseded record.Tests
python -m pytest tests -q -n auto: 1268 → 1282 passed.test_profiling_conductor.py(48 → 56): new-tree coverage, dispatch routing, class mismatch, envelope pin, v2 byte-identical, bad grammar in records and tree, archived/unknown class refused.test_samplers_surface.py(17 → 20).ruff check .: 59 findings both before and after. None are new; the only one in a touched file is a pre-existing E741 in_samplers.benchmarks.Deviations
tmp_pathfollowing the existing hermetic_workspace(tmp_path)pattern. There is notests/fixtures/profiling_v3_tree/, which the issue allowed.profiling-summary@3has no envelope release pin, so "the catalogue's pin" is the envelope'srelease_pinif one is present, otherwise the newest record pin. The output reports which.host_classand--tieris echoed but not used to filter (tier_notein the output).profiling.mdandlifecycle.mdonly.Blocked-by:values in the template name the epic phase (lifecycle-<…> Phase N), because the earlier phase's issue number is not known when the template is rendered. Rendering rule 4 allows replacing it with aRepo#Nref at filing.Closes #535
🤖 Generated with Claude Code
API Changes
pyauto-brain profiling campaignoutput: unchanged for v2/absent catalogues (byte-identical); on aprofiling-summary@3catalogue the decision carries the new lifecycle coverage grid (per likelihood × class × measurement, cells current/stale/superseded/missing) and routes byhost_class(--tierechoed).SetupIdErrorraised on asetup_idthat violates<backend>_<device>_<operator>_<precision>[_<transformer>], in the catalogue or in results-tree folder names.scripts/<dataset_type>/<variant>/validation/leaves. autofit_inference tier unchanged.skills/profiling/lifecycle.md(no CLI change; phase 8 adds the verb).