Skip to content

Normalize Codex dynamic tool transcript shape#80155

Merged
scoootscooob merged 2 commits into
mainfrom
codex/codex-toolsearch-transcript-shape
May 10, 2026
Merged

Normalize Codex dynamic tool transcript shape#80155
scoootscooob merged 2 commits into
mainfrom
codex/codex-toolsearch-transcript-shape

Conversation

@scoootscooob

@scoootscooob scoootscooob commented May 10, 2026

Copy link
Copy Markdown
Member

Summary

  • Add common transcript aliases to Codex app-server mirrored tool calls/results (input on tool calls, id/name/toolName on tool result blocks) while preserving the existing canonical fields.
  • Add a searchable dynamic-tool regression proving Codex tool search remains internal and mirrored snapshots expose the real OpenClaw tool call/result shape.

Real behavior proof

  • Behavior or issue addressed: Codex app-server mirrored transcript snapshots should expose compatibility aliases for dynamic tool calls/results without leaking tool_search or function_call_output markers.
  • Real environment tested: macOS local OpenClaw worktree checked out at PR Normalize Codex dynamic tool transcript shape #80155, Node v25.2.1, pnpm 10.33.2, production CodexAppServerEventProjector loaded through tsx.
  • Exact steps or command run after this patch: Ran pnpm exec tsx -e '<script>' that constructs the production Codex app-server event projector, records a dynamic wiki_status tool call/result pair, builds the mirrored messages snapshot, and prints the actual projected tool-call/tool-result records.
  • Evidence after fix: Terminal output from the after-fix projector smoke:
{
  "roles": [
    "user",
    "assistant",
    "toolResult"
  ],
  "toolCall": {
    "type": "toolCall",
    "id": "call-wiki-status-proof",
    "name": "wiki_status",
    "arguments": {
      "topic": "README.md"
    },
    "input": {
      "topic": "README.md"
    }
  },
  "toolResult": {
    "type": "toolResult",
    "id": "call-wiki-status-proof",
    "name": "wiki_status",
    "toolName": "wiki_status",
    "toolCallId": "call-wiki-status-proof",
    "toolUseId": "call-wiki-status-proof",
    "tool_use_id": "call-wiki-status-proof",
    "content": "wiki_status done",
    "text": "wiki_status done"
  },
  "containsToolSearch": false,
  "containsFunctionCallOutput": false
}
  • Observed result after fix: The mirrored snapshot contains the new alias fields while preserving canonical arguments, toolCallId, toolUseId, and tool_use_id, and it does not contain tool_search or function_call_output.
  • What was not tested: A live external Codex SaaS/app-server network turn was not run; this proof exercises the local production projector path for the mirrored transcript records changed by this PR.

Verification

  • node scripts/test-extension.mjs extensions/codex -- --run (47 files, 607 tests)

@clawsweeper

clawsweeper Bot commented May 10, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

Summary
The branch adds additive input/id/name/toolName aliases to Codex app-server mirrored tool-call/result transcript records and adds regression coverage for searchable dynamic tools.

Reproducibility: not applicable. this is a compatibility cleanup PR rather than a reported bug. Source inspection and the PR's terminal proof both exercise the affected dynamic-tool projection path.

Real behavior proof
Sufficient (terminal): The PR body now includes after-fix terminal output from a local production projector smoke showing the alias fields and absence of Tool Search wrapper markers.

Next step before merge
Protected-label transcript contract work needs normal maintainer review/merge handling; there is no narrow automated repair to queue.

Security
Cleared: The diff only changes mirrored transcript fields and tests, with no dependency, workflow, permission, secret-handling, or new code-execution surface.

Review details

Best possible solution:

Keep the additive aliases in the Codex app-server mirror projection if maintainers want this compatibility shape, while leaving the paired core/native transcript projection to #80164.

Do we have a high-confidence way to reproduce the issue?

Not applicable: this is a compatibility cleanup PR rather than a reported bug. Source inspection and the PR's terminal proof both exercise the affected dynamic-tool projection path.

Is this the best way to solve the issue?

Yes for the code shape: adding aliases in the projector while preserving canonical fields is the narrowest maintainable implementation I found. Maintainer judgment is still needed because this changes a transcript compatibility surface and the PR has the protected maintainer label.

What I checked:

Likely related people:

  • scoootscooob: Authored the merged commit that added Codex app-server tool-call mirroring in the same projector/run-attempt path, beyond authoring this PR. (role: current-main transcript mirror contributor; confidence: high; commits: 480af0300916; files: extensions/codex/src/app-server/event-projector.ts, extensions/codex/src/app-server/run-attempt.ts)
  • steipete: Recent path history ties this person to Tool Search docs and adjacent Codex dynamic-tool behavior that frames this transcript-shape change. (role: recent Tool Search and Codex dynamic-tool contributor; confidence: medium; commits: 1576853fbcd7, 8e0486c6b795, b62166301efd; files: docs/tools/tool-search.md, extensions/codex/src/app-server/run-attempt.ts)
  • kevinslin: Recent path history shows adjacent work removing the Codex dynamic tools profile option in run-attempt.ts. (role: recent Codex dynamic-tools area contributor; confidence: medium; commits: b79de62b3c48; files: extensions/codex/src/app-server/run-attempt.ts)

Codex review notes: model gpt-5.5, reasoning high; reviewed against 400dc28e6d29.

@clawsweeper clawsweeper Bot added the proof: sufficient ClawSweeper judged the real behavior proof convincing. label May 10, 2026
@scoootscooob
scoootscooob force-pushed the codex/codex-toolsearch-transcript-shape branch from bb2bbc4 to 5298016 Compare May 10, 2026 08:17
@scoootscooob
scoootscooob merged commit f9d4e0c into main May 10, 2026
105 checks passed
@scoootscooob
scoootscooob deleted the codex/codex-toolsearch-transcript-shape branch May 10, 2026 08:22
longstoryscott pushed a commit to longstoryscott/openclaw that referenced this pull request May 13, 2026
* Normalize Codex dynamic tool transcript shape

* test: align codex transcript aliases
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request May 24, 2026
* Normalize Codex dynamic tool transcript shape

* test: align codex transcript aliases
jameslcowan pushed a commit to jameslcowan/openclaw that referenced this pull request Jun 2, 2026
* Normalize Codex dynamic tool transcript shape

* test: align codex transcript aliases
sablehead pushed a commit to sablehead/openclaw that referenced this pull request Jun 10, 2026
* Normalize Codex dynamic tool transcript shape

* test: align codex transcript aliases
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

extensions: codex maintainer Maintainer-authored PR proof: sufficient ClawSweeper judged the real behavior proof convincing. size: S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant