Skip to content

Relocate the Health Agent into PyAutoBrain (canonical home) - #2

Merged
Jammy2211 merged 2 commits into
mainfrom
claude/health-agent-relocate-brain-qh84mk
Jun 29, 2026
Merged

Relocate the Health Agent into PyAutoBrain (canonical home)#2
Jammy2211 merged 2 commits into
mainfrom
claude/health-agent-relocate-brain-qh84mk

Conversation

@Jammy2211

Copy link
Copy Markdown
Contributor

What & why

The Health Agent (the first PyAutoBrain specialist) was implemented and staged in PyAutoHeart at health_agent/ while PyAutoBrain was out of scope. PyAutoBrain is now in scope, so the reasoning agent moves to its canonical home, preserving the boundary:

Mind (intent) -> Brain (reasoning) -> Heart (gate) -> Hands/Build (execute)

Changes

  • agents/health/AGENTS.md becomes the canonical Health Agent definition, folded into Brain's own discovery pattern (agents/<name>/AGENTS.md + health.sh entrypoint, unchanged) and surfaced by pyauto-brain help health. 131 lines (under the 200-line cap).

Preserved verbatim from the staged health_agent.md:

  • adoption of pyauto-heart readiness --json as the authoritative verdict (never re-derived from raw checks);
  • reading PyAutoHeart's capabilities.yaml as an abstract provider manifest — read from the PyAutoHeart checkout, never vendored/copied into Brain;
  • the GREEN/YELLOW/RED output schema (Summary / Warnings / Recommendations / Blocking Issues), gate semantics, and the read-and-reason hard boundaries (never write repos, run builds, trigger releases, or implement a check).

Boundary preserved

No health checks or gating logic were added to Brain — it only reasons over Heart's outputs. The companion changes land in PyAutoHeart (keeps its self-describing capability manifest, repoints health_agent/README.md here) and PyAutoMind (marks the migration follow-up complete).

Validation

  • pyauto-brain help health renders the relocated definition.
  • pyauto-heart readiness --json returns the { verdict, score, red_reasons[], yellow_reasons[], ts } schema the agent adopts.
  • PyAutoHeart pytest tests/ → 105 passed (companion PR).

🤖 Generated with Claude Code


Generated by Claude Code

The Health Agent (first PyAutoBrain specialist) was staged in PyAutoHeart's
health_agent/ while Brain was out of scope. Relocate its full definition into
Brain's own discovery pattern: agents/health/AGENTS.md is now the canonical
agent definition (entrypoint health.sh unchanged), surfaced by
`pyauto-brain help health`.

Preserves verbatim from the staged health_agent.md: adoption of
`pyauto-heart readiness --json` as the authoritative verdict (never re-derived),
reading Heart's capabilities.yaml as an ABSTRACT provider manifest (read from the
PyAutoHeart checkout, never vendored into Brain), the GREEN/YELLOW/RED output
schema (Summary / Warnings / Recommendations / Blocking Issues), gate semantics,
and the read-and-reason hard boundaries. No checks or gating logic added to Brain.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015tHLhoSDd7CVvrJ8k7nc7z
Copilot AI review requested due to automatic review settings June 29, 2026 11:26

Copilot AI 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.

Pull request overview

Relocates and expands the Health Agent’s canonical documentation into PyAutoBrain, describing how the agent should reason over PyAutoHeart’s health/readiness outputs while preserving the Mind → Brain → Heart → Hands boundary.

Changes:

  • Rewrites agents/health/AGENTS.md to document the Health Agent’s role, boundaries, and interaction model with PyAutoHeart.
  • Adds a detailed procedure and output schema for how the agent should interpret Heart’s readiness/status signals.
  • Clarifies “abstract provider” coupling via PyAutoHeart’s capability manifest (not vendored into Brain).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread agents/health/AGENTS.md Outdated
Comment on lines +3 to +5
The first PyAutoBrain specialist reasoning agent. It decides whether the PyAuto
organism is healthy enough to proceed with work, by **reasoning over
PyAutoHeart's outputs** — never by performing health checks itself.
Comment thread agents/health/AGENTS.md Outdated
Comment on lines 41 to 44
@@ -27,17 +44,88 @@ bin/pyauto-brain health status # forward to: pyauto-heart status
bin/pyauto-brain health watch 300 # forward to: pyauto-heart watch 300
Comment thread agents/health/AGENTS.md
Comment on lines +58 to +62
This returns `{ verdict, score, red_reasons[], yellow_reasons[], ts }`. The
`verdict` is Heart's decision — adopt it; do not re-derive it from raw checks.
If the command is unavailable, fall back to the persisted
`~/.pyauto-heart/release_ready.json`; if neither exists, the verdict is
**unknown -> treat as YELLOW** and recommend running `pyauto-heart tick`.
Comment thread agents/health/AGENTS.md
Comment on lines +80 to +83
4. **Determine overall readiness** by adopting Heart's `verdict`:
- any `red_reasons` -> **RED**
- else any `yellow_reasons` -> **YELLOW**
- else **GREEN**
- Drop the "first" specialist claim (agents/release/ predates and is listed
  ahead of agents/health/ in the top-level AGENTS.md).
- Fix the Run example: `health --json` forwards to `pyauto-heart --json`, an
  unknown subcommand; use `health readiness --json` (forwarded, no tick).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015tHLhoSDd7CVvrJ8k7nc7z
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.

3 participants