docs: golden-agent adoption plan for the unified harness surface#422
Draft
declan-scale wants to merge 4 commits into
Draft
docs: golden-agent adoption plan for the unified harness surface#422declan-scale wants to merge 4 commits into
declan-scale wants to merge 4 commits into
Conversation
37421b6 to
df3461c
Compare
10e753f to
5003af8
Compare
ccbd5cf to
e3fa1cc
Compare
1fdeb33 to
83a7a28
Compare
danielmillerp
approved these changes
Jun 22, 2026
| @@ -0,0 +1,93 @@ | |||
| # Golden Agent — Adopting the Unified Harness Surface | |||
|
|
|||
Contributor
There was a problem hiding this comment.
hmm can we not put this under superpowers? if it is worthy of doc maybe in notion? or in https://agentex.sgp.scale.com/docs
c8c63d1 to
05120f3
Compare
8de7221 to
0bb3161
Compare
05120f3 to
c9a907c
Compare
0bb3161 to
02ff283
Compare
c9a907c to
a04bf5e
Compare
Base automatically changed from
declan-scale/agx1-373-conformance-equivalence
to
next
June 22, 2026 20:09
Migration plan (implementation in agentex-agents/golden_agent): replace the bespoke HarnessEvent/AgentexStreamAdapter + per-provider parsers with the SDK taps + UnifiedEmitter, keeping all SGP-coupled orchestration (sandbox pool, secrets, MCP reauth, data-plane override). Phased: claude-code -> codex -> delete harness layer -> optional in-process OpenAI-Agents. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- Step 4 pseudocode now chains at the canonical StreamTaskMessage level (convert_claude_code_to_agentex_events(stdout)) to match the "Sandbox-setup event interleaving" prose; ClaudeCodeTurn does not accept raw stdout lines alongside parsed events. - Disposition table now labels the in-process OpenAI-Agents harness as Phase 4 (optional), matching the Phases section (Phase 2 is the codex provider). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…tile] The target-flow pseudocode (and the Phase 1 + Determinism subsections) called workflow.now() from inside execute_agent_turn, which is a Temporal activity — workflow.now() is only valid in workflow context and raises in an activity. Show the workflow capturing workflow.now() and passing it into the activity as a created_at parameter, with the activity forwarding params.created_at to auto_send_turn. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…ptile] - Determinism section: stop claiming created_at forwarding "matches the prior dispenser behavior". auto_send_turn stamps every message in the turn with the same created_at, whereas the dispenser stamped only the first agent message (later ones took server time). Note the intra-turn ordering implication and the created_at=None / per-message alternatives. - Phase 4: reference the real SDK openai tap (convert_openai_to_agentex_events wrapped in a HarnessTurn; OpenAITurn lands in the openai migration PR) instead of implying OpenAITurn is already on the public surface, and clarify that run_agent_streamed_auto_send is the existing provider wrapper, not the tap/Turn migration target. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
02ff283 to
1d66f7a
Compare
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.
The capstone plan for the unified harness surface workstream: how
golden_agent(inagentex-agents) adopts the SDK taps +UnifiedEmitter, retiring its bespokeHarnessEvent/AgentexStreamAdapter+ per-provider parsers while keeping all SGP-coupled orchestration (sandbox pool, secrets, MCP reauth, data-plane override).Phased: prereqs (pin SDK) → claude-code → codex → delete the harness layer → optional in-process OpenAI-Agents. Implementation lands in
agentex-agents, after this SDK stack merges + releases.🤖 Generated with Claude Code
Greptile Summary
This PR adds a planning document for migrating the
golden_agentinagentex-agentsfrom its bespokeHarnessEvent/AgentexStreamAdapterlayer to the SDK's unified harness surface (convert_<harness>_to_agentex_eventstaps +<Harness>Turn+UnifiedEmitter), while leaving all SGP-coupled concerns (sandbox pool, secrets, MCP reauth, data-plane override) untouched.Confidence Score: 5/5
Documentation-only change with no runtime code; safe to merge.
This is a planning document with no executable code. All three prior review concerns (phase label alignment, timestamp delta from old dispenser, OpenAI API surface) have been addressed in the current revision. The one remaining gap —
HarnessTurnappearing as an undefined symbol alongsideOpenAITurnin Phase 4 — is a minor naming inconsistency that would not block an implementer from understanding the intent.No files require special attention; the single changed file is a markdown planning document.
Important Files Changed
HarnessTurn) in the Phase 4 description; all previous review concerns (phase label, timestamp delta, OpenAI API surface) have been addressed in the current revision.Flowchart
%%{init: {'theme': 'neutral'}}%% flowchart TD P0[Phase 0 — Prereqs\nMerge + release SDK stack\nPin scale-agentex version\nCommit uv.lock] P1[Phase 1 — claude-code\nKeep ClaudeProvider sandbox/spawn\nReplace _StreamJsonProcessor + HarnessEvent\nClaudeCodeTurn + UnifiedEmitter.auto_send_turn\nDelete _StreamJsonProcessor] P2[Phase 2 — codex\nSame pattern with CodexTurn\nDelete _CodexEventProcessor] P3[Phase 3 — retire bespoke harness\nDelete harness/events.py\nDelete harness/adapter.py\nShrink/delete harness/protocol.py\nSimplify harness/activity.py] P4[Phase 4 — optional OpenAI-Agents\nAdopt convert_openai_to_agentex_events\nOpenAITurn pending openai migration PR\nTrickiest — deferred] KEEP[(Keep unchanged\nSandbox pool/setup\nSecrets/MCP reauth\nData-plane override\nCapabilities/workflow/cron)] P0 --> P1 P1 --> P2 P2 --> P3 P3 -.->|optional, later| P4 P1 & P2 & P3 & P4 --- KEEP%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%% flowchart TD P0[Phase 0 — Prereqs\nMerge + release SDK stack\nPin scale-agentex version\nCommit uv.lock] P1[Phase 1 — claude-code\nKeep ClaudeProvider sandbox/spawn\nReplace _StreamJsonProcessor + HarnessEvent\nClaudeCodeTurn + UnifiedEmitter.auto_send_turn\nDelete _StreamJsonProcessor] P2[Phase 2 — codex\nSame pattern with CodexTurn\nDelete _CodexEventProcessor] P3[Phase 3 — retire bespoke harness\nDelete harness/events.py\nDelete harness/adapter.py\nShrink/delete harness/protocol.py\nSimplify harness/activity.py] P4[Phase 4 — optional OpenAI-Agents\nAdopt convert_openai_to_agentex_events\nOpenAITurn pending openai migration PR\nTrickiest — deferred] KEEP[(Keep unchanged\nSandbox pool/setup\nSecrets/MCP reauth\nData-plane override\nCapabilities/workflow/cron)] P0 --> P1 P1 --> P2 P2 --> P3 P3 -.->|optional, later| P4 P1 & P2 & P3 & P4 --- KEEPReviews (8): Last reviewed commit: "docs: correct timestamp + OpenAI-tap cla..." | Re-trigger Greptile