Repository navigation
feat(harness): register and detect prime-agent adapter - #4004
Closed
eduardstan wants to merge 11 commits into
Closed
eduardstan wants to merge 11 commits into
eduardstan wants to merge 11 commits into
Conversation
…ispatch validation
Confidence Score: 5/5The PR appears safe to merge with no concrete changed-code defect identified. Prime Agent registration is consistently implemented across detection, dispatch validation, launch construction, lifecycle control, cleanup, documentation, and focused regression coverage. Reviews (1): Last reviewed commit: "no-mistakes(document): Add prime-agent t..." | Re-trigger Greptile |
Author
|
Opened by our validation pipeline in error; this work is the refresh of #2062, which now carries the same head. |
Owner
|
Speaking as Kun's firstmate: Closing the leftover: this PR was opened by the validation pipeline in error and carries the same head as #2062 ( |
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.
Intent
Upstream firstmate (kunchenguid/firstmate) triaged our proposal issue #3953 and answered: the Prime Agent adapter is aligned with their vision, and the path is our three open pull requests in order, #2062 (register and detect the prime-agent harness adapter), #2070 (classify and probe prime-agent panes under Herdr), #2075 (retire prime-agent detached daemon sessions at teardown). No parallel adapter PR. The captain this morning: "If we need to run no-mistakes, do it for the upstream to hopefully merge our PR(s)."
This task is the first slice, PR 2062. Its branch is fork/fm/fm-upstream-prime-slice1 (check the PR's head ref), opened against upstream main months ago; upstream main has moved (about 18 commits since our last alignment plus everything before), one CI check fails ("Behavior portable serial 4"), and the PR body is 58 KB of history that upstream's reviewer will not read. Upstream requires the no-mistakes pipeline on PRs, with the gate capping a PR at about 20 changed files and 1000 changed lines (the reason for the split), and our own fork now carries the complete verified adapter on 0.9.1 (eduardstan#10 evidence).
What Changed
CLAUDECODEfalse positives) with verified-marker precedence preserved..agents/skills/harness-adapters/references/harness/prime-agent.mdand wire prime-agent into verified-harness lists acrossAGENTS.mdanddocs/agent-control.md,docs/architecture.md,docs/configuration.md,docs/documentation-audiences.json,docs/trace-context.md.tests/fm-prime-agent-harness.test.shandtests/fm-spawn-dispatch-profile.test.shcovering marker detection, dispatch profile registration, and teardown behavior.Risk Assessment
✅ Low: This final round correctly implements every previously-decided fix (exact prime-agent family match instead of prefix guess, clear-key assertion now checks success before emptiness, dispatch-validate and usage-header lists updated) with no residual gaps, no scope creep, and the diff stays well under the 20-file/1000-line cap.
Testing
All prime-agent register/detect/launch/control/teardown scenarios pass live via the project's own bash test suite driving real fm-harness.sh/fm-spawn.sh/fm-control-lib.sh/fm-teardown.sh against fake tmux/git fixtures; the crew-dispatch validator's new prime-agent acceptance was confirmed live by temporarily adding a table row and running the real jq-backed validator through fm-bootstrap.sh, then reverting the test file. Separately reproduced the intent-named CI failure ("Behavior portable serial 4"): base commit's bin/fm-test-run.sh --check-coverage fails under LC_ALL=en_US.utf8 with "comm: input is not in sorted order", while the target commit passes under both C and en_US.utf8 locales, confirming the LC_ALL=C comm fixes are the actual fix.
Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
✅ **Review** - passed
✅ No issues found.
✅ **Test** - passed
✅ No issues found.
bash tests/fm-prime-agent-harness.test.sh (harness detection precedence, marker anchoring, control-lib lifecycle table)bash tests/fm-spawn-dispatch-profile.test.sh (prime-agent launch marker establishment, prime-agent secondmate named refusal, all other dispatch profiles)bash tests/fm-trace-context-spawn.test.sh (regression check on shared spawn path)LC_ALL=C bin/fm-test-run.sh --check-coverage vs LC_ALL=en_US.utf8 bin/fm-test-run.sh --check-coverage, on both target commit and base commit's bin/fm-test-run.shtemporary row added to tests/fm-bootstrap.test.sh crew_dispatch_validation table (prime-agent + effort:max) run via bash tests/fm-bootstrap.test.sh, then reverted✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.