Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions .claude/hooks/session-start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -132,12 +132,13 @@ marked_root() {
holds_an_organ() {
[ -d "$1/PyAutoBrain" ] || [ -d "$1/PyAutoMind" ] || [ -d "$1/PyAutoCortex" ] \
|| [ -d "$1/PyAutoMemory" ] || [ -d "$1/PyAutoEyes" ] || [ -d "$1/PyAutoHeart" ] \
|| [ -d "$1/PyAutoHands" ] || [ -d "$1/PyAutoNerves" ] || [ -d "$1/PyAutoGut" ] \
|| [ -d "$1/PyAutoHands" ] || [ -d "$1/PyAutoPulse" ] || [ -d "$1/PyAutoNerves" ] \
|| [ -d "$1/PyAutoGut" ] \
|| [ -d "$1/organs/PyAutoBrain" ] || [ -d "$1/organs/PyAutoMind" ] \
|| [ -d "$1/organs/PyAutoCortex" ] || [ -d "$1/organs/PyAutoMemory" ] \
|| [ -d "$1/organs/PyAutoEyes" ] || [ -d "$1/organs/PyAutoHeart" ] \
|| [ -d "$1/organs/PyAutoHands" ] || [ -d "$1/organs/PyAutoNerves" ] \
|| [ -d "$1/organs/PyAutoGut" ]
|| [ -d "$1/organs/PyAutoHands" ] || [ -d "$1/organs/PyAutoPulse" ] \
|| [ -d "$1/organs/PyAutoNerves" ] || [ -d "$1/organs/PyAutoGut" ]
}

# Assigns WORKSPACE_ROOT and WORKSPACE_ROOT_REASON rather than printing: one
Expand Down
1 change: 1 addition & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ Canonical boundaries live in `PyAutoBrain/ORGANISM.md`; the full body map
| **Eyes** | PyAutoEyes | The Eyes — where the organism sees what its figures look like: the cross-project visualization dashboard over the `<lib>_visualization` project repos (autolens_visualization, autogalaxy_visualization, autofit_visualization and autocti_visualization) — the registry of those repos, the tracked-manifest read contract (`gallery/viz_manifest.yaml`) and the Pages board that links to their PNGs as the single point of contact for the visual behaviour of the whole ecosystem. Renders nothing and copies no figures (the project repos render and hold them); never judges them (the Brain's Eyes conductor does) and never edits library plot code (critiques route through intake). |
| **Heart** | PyAutoHeart | Health/readiness — the authoritative "is it safe to release?" verdict. |
| **Hands** | PyAutoHands | Packaging, tagging, notebook generation, PyPI release execution. |
| **Pulse** | PyAutoPulse | The Pulse — where the organism feels how fast it runs: the cross-project profiling dashboard over the `<lib>_profiling` project repos (today autolens_profiling) — the instance registry, the versioned `profiling-summary` read contract (v1 live at `autolens_profiling/dashboard/summary.json`), the ingest receipts (resolved commit per project per render) and the Pages board. Validates the exchange contract only; never moves pins, combines unmatched timings, applies the compile threshold to runtime, computes an ecosystem-wide speed score or issues a Heart verdict, and never judges (the Brain's profiling conductor does); the project repos keep their producers, results, drift policy and their own Pages page. |
| **Nerves** | PyAutoNerves | The Nerves — the configuration/serialization layer connecting workspace conventions to libraries (layered config, version handshake, test_mode), delivered as the `autonerves` package. |
| **Gut** | PyAutoGut | Owns the lifecycle of condemned self-material (stale branches, stashes, dead code/tests): holds it as durable, recoverable git refs through a transit window and voids it on a sweep. The storage mirror of Memory (retention vs release). |

Expand Down
11 changes: 9 additions & 2 deletions ORGANISM.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ organs plan, build, test and release it, and you make every judgment call.
| **Eyes** | PyAutoEyes | Sees *what the figures look like* across the `<lib>_visualization` project repos. Owns the instance registry, the manifest read contract and the dashboard that links to project-owned PNGs. Project repos own producers, render harnesses, figures and manifests; Eyes renders no figures and copies none. The Brain's Eyes conductor drives review and judgment; accepted critiques route through intake, never directly into library plot code. |
| **Heart** | PyAutoHeart | Determines whether the organism is healthy. `pyauto-heart readiness` is the **authoritative** GREEN/YELLOW/RED "is it safe to release?" gate. An observer: never writes into other repos, never triggers Build. |
| **Hands** | PyAutoHands | Builds and releases — packaging, tagging, notebook generation, PyPI via `release.yml`. A pure executor: runs no readiness checks and never re-derives a gate decision. |
| **Pulse** | PyAutoPulse | Feels *how fast the organism runs* across the `<lib>_profiling` project repos. Owns the profiling instance registry, the versioned `profiling-summary` read contract, the ingest receipts (resolved commit per project per render) and the cross-project board. Validates the exchange contract only; project repos own producers, results, pins, drift policy and their own Pages page. Never moves pins, combines unmatched timings, applies the compile threshold to runtime, computes an ecosystem-wide speed score or issues a readiness verdict; the Brain's profiling conductor (`triage`) is the only judge. |
| **Nerves** | PyAutoNerves | The configuration/serialization layer (`autonerves`) — layered config with overrides, the workspace↔library version handshake, `test_mode`, FITS/JSON I/O. Connects the organism's conventions to every library; the base layer the scientific libraries all import. |
| **Gut** | PyAutoGut | Owns the lifecycle of *condemned self-material* — stale branches, stashes, dead code/tests. Holds each as a durable, recoverable git ref through a transit window and **voids** it on a sweep. The storage mirror of Memory (retention ↔ release); the hygiene conductor drives it, as vitals reads Heart. |

Expand Down Expand Up @@ -98,7 +99,7 @@ human types); let faculties multiply behind them.
New capability grows as a **faculty** (cheap: one directory, one doc, one
script), not as a repo. A new organ costs an `AGENTS.md`, a `CLAUDE.md` stub,
install wiring, a body-map row and boundary prose — it must earn that by
owning state or effects no existing organ can. Three capabilities have earned
owning state or effects no existing organ can. Four capabilities have earned
organ status that way. Configuration/signalling is the **Nerves**
(PyAutoNerves), the base config/serialization layer every library imports — new
config surfaces belong there, not in a new organ. Keeping track of what is
Expand All @@ -109,7 +110,13 @@ the Mind. Seeing what the software shows is the **Eyes** (PyAutoEyes): it owns
the cross-project instance registry, manifest read contract and dashboard.
Each visualization project retains its render harness, figures and generated
manifest; the organ reads those manifests and links to the figures. The
Brain's Eyes conductor owns review and judgment. A dashboard alone does not
Brain's Eyes conductor owns review and judgment. Feeling how fast the software
runs is the **Pulse** (PyAutoPulse), the fourth: the same layering over the
`<lib>_profiling` project repos — it owns the profiling instance registry, the
versioned `profiling-summary` read contract, the ingest receipts and the
cross-project board, while each profiling project keeps its producers, results
and drift policy and the Brain's profiling conductor stays the only judge. A
dashboard alone does not
waive the state-or-effects requirement for a new organ. The human interaction
layer is the command surface (`/route` + the verb commands), which is part of
Brain.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,10 @@ the linked canonical file retains the full instructions. Commit the generated
adapters with the skill. Regeneration checks name collisions across the installed
repository inventory and refuses conflicting user-owned destinations.

The nine organs the Brain coordinates — Brain (reasoning), Mind (intent),
The ten organs the Brain coordinates — Brain (reasoning), Mind (intent),
Cortex (learning what is true), Memory (knowledge), Eyes (seeing the
figures), Heart (health), Hands (release), Nerves (configuration), Gut
(shedding) —
figures), Heart (health), Hands (release), Pulse (feeling how fast it runs),
Nerves (configuration), Gut (shedding) —
are defined once in
[ORGANISM.md](ORGANISM.md), which this
repo hosts. Agent contracts and the generated command table are in
Expand Down
1 change: 1 addition & 0 deletions agents/_pyauto_root.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
"PyAutoEyes",
"PyAutoHeart",
"PyAutoHands",
"PyAutoPulse",
"PyAutoNerves",
"PyAutoGut",
)
Expand Down
8 changes: 8 additions & 0 deletions agents/conductors/profiling/AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,14 @@ as malformed — only a record missing *some* of its key fields is corruption.
loop's cost (unit-test time, `PYAUTO_TEST_MODE` / `PYAUTO_SMALL_DATASETS`
scripts, import time) and repo tidiness. Hunting generally-slow functions
flagged by integration tests is hygiene's `perf` mode, not profiling's.
- **vs the Pulse** — the **Pulse** organ (PyAutoPulse, `ORGANISM.md`) holds
the cross-project view: the registry of `<lib>_profiling` projects, the
versioned `profiling-summary` read contract, ingest receipts and the board.
It validates the exchange contract only and never judges; this conductor
(`triage`) stays the only judge of what a timing or a drift means, with the
human. The projects keep their producers, results, pins and drift policy.
Same split as Heart ↔ vitals and Eyes ↔ the Eyes conductor. (Organ row
born in PyAutoMind#463; its reader and board arrive in phase 2.)
- **vs build** — campaigns are not releases; `profile.yml`'s on-release runs
stay CI/Build territory.
- **release-validation script cost is NOT ours.** The compile axis was
Expand Down
2 changes: 1 addition & 1 deletion bin/_pyauto_root.sh
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ _pyauto_marked_root() {
_pyauto_is_root() {
[ -d "$1/PyAutoMind" ] || [ -d "$1/PyAutoCortex" ] || [ -d "$1/PyAutoMemory" ] \
|| [ -d "$1/PyAutoEyes" ] || [ -d "$1/PyAutoHeart" ] || [ -d "$1/PyAutoHands" ] \
|| [ -d "$1/PyAutoNerves" ] || [ -d "$1/PyAutoGut" ]
|| [ -d "$1/PyAutoPulse" ] || [ -d "$1/PyAutoNerves" ] || [ -d "$1/PyAutoGut" ]
}

# Assigns PYAUTO_ROOT and PYAUTO_ROOT_REASON rather than printing: one
Expand Down
5 changes: 4 additions & 1 deletion bin/clean_slate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,10 @@ PACKAGING_REPOS=(PyAutoNerves PyAutoFit PyAutoArray PyAutoGalaxy PyAutoLens)
# lens hst imaging is a byte-identical copy of autolens_profiling's) and their
# PNG renders are the tracked record (re-rendered on library release only) —
# never wiped. The Eyes organ (organs/PyAutoEyes) is the cross-project dashboard
# over such project repos and holds no datasets of its own to wipe.
# over such project repos and holds no datasets of its own to wipe. The Pulse
# organ (organs/PyAutoPulse) is likewise the cross-project profiling dashboard
# over the <lib>_profiling project repos: it reads their summaries and holds no
# datasets of its own to wipe.
DATASET_REPOS=(autolens_workspace autogalaxy_workspace autofit_workspace \
autocti_workspace HowToLens HowToGalaxy HowToFit)
# Committed dataset files above this size are flagged as repo bloat.
Expand Down
14 changes: 8 additions & 6 deletions docs/concepts/organism.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ it and adds the framework/instance distinction an adopter needs.
| **Eyes** | PyAutoEyes | *Sees* — the cross-project visualization registry, manifest read contract and dashboard. Project repos render and hold figures; Eyes links to them. The Brain's Eyes conductor handles judgment. |
| **Heart** | PyAutoHeart | Decides whether the organism is *healthy*. `pyauto-heart readiness` is the authoritative GREEN/YELLOW/RED release gate. An observer: never writes into other repos, never triggers a build. |
| **Hands** | PyAutoHands | *Does* — packaging, tagging, notebook generation, PyPI releases. A pure executor: never re-derives a gate decision. |
| **Pulse** | PyAutoPulse | *Feels* — the cross-project profiling registry, the versioned `profiling-summary` read contract, ingest receipts and dashboard. Project repos produce and hold timings; Pulse validates the exchange and links to them. The Brain's profiling conductor handles judgment. |
| **Nerves** | PyAutoNerves | *Connects* — the configuration/serialization layer (`autonerves`): layered config, the workspace↔library version handshake, `test_mode`, FITS/JSON I/O. The base layer every library imports. |
| **Gut** | PyAutoGut | *Sheds* — the lifecycle of condemned self-material (stale branches, stashes, dead code/tests): holds each as a durable, recoverable git ref through a transit window, then **voids** it on a sweep. The storage mirror of Memory (retention ↔ release); the hygiene conductor drives it, as vitals reads Heart. |

Expand All @@ -34,8 +35,9 @@ is the container, and a workspace is one familiar kind of project.

These roles do not replace the {doc}`repository categories <../satellites>` or
change their workflow and release gates. Profiling, inference and visualization
repos illustrate the project role; Eyes provides an existing cross-project
organ view. The project-to-organ boundary is described in {doc}`../organs/eyes`.
repos illustrate the project role; Eyes and Pulse provide cross-project organ
views over the visualization and profiling projects. The project-to-organ
boundary is described in {doc}`../organs/eyes` and {doc}`../organs/pulse`.

## The call chain

Expand All @@ -57,10 +59,10 @@ The organs split on one line that matters for adoption:
pipelines. Domain facts appear only in declared config surfaces (tables
and policy files, not logic), and a drift check — the
{ref}`tenant firewall <tenant-firewall>` — keeps it that way.
- **Instance organs — Mind, Cortex, Memory, Eyes, Gut.** Committed state,
ledgers, knowledge, visualization registries and shed material. These are
*inherently yours*: an adopter never forks the upstream Mind, Cortex, Memory,
Eyes or Gut content, they create their own repos with the same documented
- **Instance organs — Mind, Cortex, Memory, Eyes, Pulse, Gut.** Committed
state, ledgers, knowledge, visualization and profiling registries and shed
material. These are *inherently yours*: an adopter never forks the upstream
Mind, Cortex, Memory, Eyes, Pulse or Gut content, they create their own repos with the same documented
shape.

One more principle worth knowing before you read anything else:
Expand Down
5 changes: 3 additions & 2 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

PyAutoScientist is a working, opinionated reference implementation of an
**AI-agent development organism** for human-led, natural-language software
development: a set of nine git repositories — Brain, Mind, Cortex, Memory,
Eyes, Heart, Hands, Nerves, Gut — through which you lead a multi-repo project in
development: a set of ten git repositories — Brain, Mind, Cortex, Memory,
Eyes, Heart, Hands, Pulse, Nerves, Gut — through which you lead a multi-repo project in
plain English. You
describe what you want; AI agents plan, implement, test, gate and release
it; you make every judgment call.
Expand Down Expand Up @@ -60,6 +60,7 @@ organs/memory
organs/eyes
organs/heart
organs/build
organs/pulse
organs/gut
```

Expand Down
78 changes: 78 additions & 0 deletions docs/organs/pulse.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
# Pulse — PyAutoPulse

**What it owns:** the **cross-project profiling view** over the
`<lib>_profiling` project repos (today `autolens_profiling`) — the instance
registry of those repos, the versioned `profiling-summary` read contract they
publish, the ingest receipts (the resolved commit per project per render) and
the board built from them. The project repos produce and hold the timings; the
organ measures nothing and copies no results. The Pulse is the speed mirror of
the Eyes: the Eyes show what the software *shows*; the Pulse feels how fast it
*runs*.

**Repo:** [PyAutoLabs/PyAutoPulse](https://github.com/PyAutoLabs/PyAutoPulse)

**Status:** organ row registered (phase 0 of the `profiling-organ-birth`
epic); the registry, reader, receipts, board and workflows arrive in phase 2.
Design: `docs/research/profiling_inference_organs.md` in the Brain repo.

## The defining function: feeling the pulse

A pulse is a rate read over time — and the question the organ answers is how
fast each library runs now, and how that has changed from release to release.
Each profiling project times its own likelihoods and searches on fixed data,
pins its baselines and applies its own drift policy; since phase 1,
`autolens_profiling` also publishes a versioned summary
(`dashboard/summary.json`, `profiling-summary` v1, grammar in
`autolens_profiling/dashboard/README.md`). The organ reads those summaries
across projects. It validates the **exchange contract** — envelope, version,
freshness, provenance — and leaves **domain semantics** to the project.

## Instances

Each instance is a `<lib>_profiling` project repo that publishes a
`profiling-summary`. `autolens_profiling` is the one real producer today. The
organ's instance registry names every instance, where its summary lives and
which contract version it speaks; each render records an ingest receipt so a
board row can always be traced to the commit it was built from. A second
project is registered only when a real producer exists — a fixture tests the
reader, an empty sibling repo is never manufactured to fill the row.

The board shows one row per registered project with scope, evidence time, last
fetch, coverage and links, and keeps missing or refused evidence visible beside
valid data. A valid empty feed says "no measurements", never "all passed".

## The driver split

The project repos *produce and hold* timings and the Pulse *shows* them;
neither judges a cross-project trend. The Brain's **profiling conductor**
(`bin/pyauto-brain profiling`, `/profiling`) plans campaigns, ingests fresh
results and triages drift with the human — `triage` is the only judge. The
same split as **Heart ↔ vitals** and **Eyes ↔ Eyes conductor**: the organ
keeps the state, the conductor reasons over it.

## What it never does

- **It never judges a timing.** Drift triage is the conductor's, with the human.
- **It never moves pins** or re-baselines a project's measurements.
- **It never combines unmatched timings** across projects, hardware or
configurations.
- **It never applies the compile threshold to runtime.** The runtime rule
(2x ratio, 1 ms floor) and the compile conductor's 1 s floor stay distinct,
as each source declares them.
- **It computes no ecosystem-wide speed score** and builds no league table
across unrelated tasks.
- **It issues no verdict.** Readiness is the Heart's.

## For an adopter

Like Mind, Cortex, Memory, Eyes and Gut, the Pulse is an **instance organ** —
inherently yours. You create your own Pulse registry and dashboard over your
own libraries' profiling project repos. Those projects produce and retain the
measurements; the organ reads their summaries and links to them.

The organ is being born through the `profiling-organ-birth` epic:

- **Phase 1** (autolens_profiling#360) published `profiling-summary` v1 from
the lens profiling project.
- **Phase 0** ([PyAutoMind#463](https://github.com/PyAutoLabs/PyAutoMind/issues/463))
added the organ row to the body map.
6 changes: 6 additions & 0 deletions skills/profiling/profiling.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,12 @@ Shared routing context: `PyAutoBrain/skills/COMMANDS.md`.
through the normal dev workflow on `autolens_profiling`, triage routes
library regressions to `bug/` via `/intake`.

The cross-project view of profiling results lives in the **Pulse** organ
(PyAutoPulse): its registry, `profiling-summary` read contract, ingest receipts
and board show how fast each `<lib>_profiling` project runs, but it never
judges. This command's `triage` is the only judge of what a timing or a drift
means; the projects keep their producers, results, pins and drift policy.

The Profiling Agent **reasons; it never runs sweeps or edits source.** The
classification is the result for CPU-unusable cells; full timings for those
belong to the A100 rows.
2 changes: 2 additions & 0 deletions tests/test_policy_seams.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,8 @@ def test_refactor_test_witness_loads():
# statement that the repo has no test suite — not a licence to skip one.
WITNESS_EXEMPT = {
"PyAutoGut": "no test suite (bin/ + docs only, verified at PyAutoBrain#269)",
"PyAutoPulse": "organ row born 2026-10-02 (profiling-organ-birth phase 0); "
"phase 2 adds tests/ and the witness row",
}


Expand Down
Loading