- Add --yolo and --accept-hooks headless auto-approval flags to spawn_spec and resume_spec
- Define Hermes TUI input delimiters (input_prompt='❯', input_rule_pattern='─{10,}')
- Refactor verify_artifact and discover in hermes.py using session started_at timestamps
- Fix HERDR_EPOCH capture timing before spawn in create_session.sh to prevent epoch race
- Update reconcile.sh for hermes drift-C multi-candidate and sibling claimed exclusion
- Add Hermes contract, epoch filtering, and C-ambiguous unit tests (140 passed)
- Add agent evaluation report and final review reports for Hermes support
51 lines
3.2 KiB
Markdown
51 lines
3.2 KiB
Markdown
# Re-review: Hermes Agent Support Audit & Modernization
|
||
|
||
- **Reviewer**: `reviewer-creator-grok-01` (role: reviewer)
|
||
- **Job**: `e46a3590` (follow-up to `53ad6a4b` `[VERDICT: NOT PASS]`)
|
||
- **Branch**: `support-hermes`
|
||
- **Prior blocking issue**: F1 — `started_at >= herdr_session_epoch` rejected the session just created, because epoch was stamped after `wait_for_tui_ready`.
|
||
|
||
## Disposition of prior findings
|
||
|
||
| ID | Prior severity | This round |
|
||
|---|---|---|
|
||
| **F1** epoch stamped after TUI ready | **Blocking** | **Fixed.** `create_session.sh` now captures `HERDR_EPOCH=$(date +%s)` immediately before `spawn()`. Verified: single assignment, `spawn` follows epoch (65 chars later), after the dry-run early-exit. |
|
||
| **F2** `discover()` still `LIMIT 1` | Non-blocking leftover | **Fixed.** Epoch-filtered `LIMIT 20` (or unfiltered `LIMIT 20` when `ctx.epoch` is 0), then `verify_artifact` per row. |
|
||
| **F3** C-ambiguous test inlines SQL, does not run `reconcile.sh` | Non-blocking quality | **Partially addressed.** New `test_hermes_reconcile_full_block_integration` covers sibling exclusion with the same gather loop. Still does not exec the embedded Python in `reconcile.sh`. Acceptable residual. |
|
||
| **F4** resume `SKILL.md` missing flags | Docs nit | **Fixed.** Example now matches `resume_session.sh`. |
|
||
|
||
New regression test `test_hermes_verify_artifact_spawn_epoch_timing_f1` encodes the intended contract: pre-spawn epoch + `started_at = epoch + 0.1` verifies; `started_at = epoch - 3600` does not; `discover()` returns only the fresh id.
|
||
|
||
## What remains correct (unchanged from first pass)
|
||
|
||
- `--yolo --accept-hooks` on spawn; `--no-restore-cwd --yolo --accept-hooks` on materialized resume — matches installed hermes CLI.
|
||
- TUI facts: `ready_tokens`, `input_prompt='❯'`, `input_rule_pattern='─{10,}'`.
|
||
- `verify_artifact` uses per-row `started_at REAL` (confirmed on live `~/.hermes/state.db`).
|
||
- `reconcile.sh` hermes drift-C: `LIMIT 20` + `started_at >= ?` + sibling-claim skip — C-ambiguous is reachable.
|
||
- Create fallback `CMD_FULL` and create `SKILL.md` `hermes)` spawn example.
|
||
|
||
## Residual nits (do not block PASS)
|
||
|
||
1. **Create SKILL.md illustrative workflow** still shows `HERDR_EPOCH=$(date +%s)` after `sleep 6`. The real script is correct; the example would reintroduce F1 if copied. Follow-up docs only.
|
||
2. **`cmd_full` table** in create SKILL.md still lists only claude/agy.
|
||
3. **F3** does not drive `reconcile.sh --once --dry-run` against a fixture. The adapter + gather-loop tests are enough for this change.
|
||
4. **`find_workspace_uuid`** still constructs `DiscoveryContext` with `epoch=0`, so the resume on-disk fallback can return multiple cwd matches and emit the newest unclaimed. Running-session pinning goes through reconcile (epoch set). Not a create-path pin failure.
|
||
|
||
None of these reintroduce silent mis-pin or unattended-flag gaps.
|
||
|
||
## Tests
|
||
|
||
```
|
||
pytest tests/test_a4_adapter_contract.py tests/test_tier1_unit.py \
|
||
tests/test_c1_tui_readiness.py tests/test_orc_onboard.py
|
||
→ 140 passed
|
||
```
|
||
|
||
Earlier-epoch capture for all agents is the right semantic for transcript mtime guards (artifacts appear after spawn). No fail-closed regression observed.
|
||
|
||
No `[ESCALATE: PLANNER]`.
|
||
|
||
---
|
||
|
||
[VERDICT: PASS]
|