-
-
Notifications
You must be signed in to change notification settings - Fork 80.7k
Track iMessage source-reply latency instrumentation #96148
Copy link
Copy link
Closed
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.bugSomething isn't workingSomething isn't workingclawsweeper:needs-live-reproClawSweeper needs live local, crabbox, or manual validation to confirm this issue.ClawSweeper needs live local, crabbox, or manual validation to confirm this issue.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.ClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.ClawSweeper does not recommend queueing a new automated fix PR for this issue.impact:otherThis issue has meaningful maintainer-visible impact outside the owned taxonomy.This issue has meaningful maintainer-visible impact outside the owned taxonomy.issue-rating: 🐚 platinum hermitGood issue quality with a plausible reproduction path needing some confirmation.Good issue quality with a plausible reproduction path needing some confirmation.maintainerMaintainer-authored PRMaintainer-authored PR
Description
Metadata
Metadata
Assignees
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.bugSomething isn't workingSomething isn't workingclawsweeper:needs-live-reproClawSweeper needs live local, crabbox, or manual validation to confirm this issue.ClawSweeper needs live local, crabbox, or manual validation to confirm this issue.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.ClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.ClawSweeper does not recommend queueing a new automated fix PR for this issue.impact:otherThis issue has meaningful maintainer-visible impact outside the owned taxonomy.This issue has meaningful maintainer-visible impact outside the owned taxonomy.issue-rating: 🐚 platinum hermitGood issue quality with a plausible reproduction path needing some confirmation.Good issue quality with a plausible reproduction path needing some confirmation.maintainerMaintainer-authored PRMaintainer-authored PR
Type
Fields
Priority
None yet
Summary
Track iMessage response latency instrumentation and follow-up performance investigation for source-reply/message-tool-only turns.
This issue captures the current evidence from a patched local worktree that included:
Observed behavior
With the Codex patch actually loaded from the worktree, iMessage ingestion and gateway routing are fast. The remaining latency is dominated by the Codex/model turn between model-call start and first tool call.
Latest live sample, redacted direct iMessage DM, model
openai/gpt-5.5, launched viapnpm openclaw gateway run --verbose:Key interpretation:
agent-run-startedtoagent-model-call-starting.agent-model-call-startingto firstbefore_tool_call.Prior samples
Before verifying Codex loaded from the patched worktree, Codex was still loading from the installed npm plugin path under
~/.openclaw/npm/projects/.../@openclaw/codex. In that state, the incomplete-turn fix was not active and runs ended with:After repointing Codex to the patched worktree build, the same flow completed cleanly with:
No
incomplete turn detectedline appeared after the patched Codex path was active.Instrumentation added locally
Repo-local files touched in the investigation branch:
extensions/imessage/src/monitor/monitor-provider.tsimessage perf:phase logs.src/auto-reply/get-reply-options.types.tsonAgentModelCallStartreply lifecycle callback.src/auto-reply/reply/agent-runner-execution.tscodex_app_server.lifecycle phase=turn_startingintoonAgentModelCallStart.extensions/imessage/src/monitor.last-route.test.tsonToolResultor changing source-reply delivery behavior.Validation run locally
Result: all targeted tests passed.
Investigation notes
codexto@openclaw/[email protected]under~/.openclaw/npm/projects/..., so the local PR Fix Codex message-tool-only source reply completion #95942 commits were present in the branch but not active in the live gateway../dist/extensions/codexcopied a built plugin whoseindex.jsstill referenced repo-root chunks, causing a missing chunk error outside the repodisttree.~/.openclaw/extensions/codexto the worktreedist/extensions/codexallowed the gateway to load the patched Codex plugin and resolve shared chunks.Open questions / next steps
message_tool_onlysource-reply path with a normal final-text reply path.Impact
Affected surface: iMessage direct-message replies using Codex/OpenAI with
sourceReplyDeliveryMode: message_tool_only.Severity: performance/user experience issue. iMessage receipt and routing are fast, but user-visible response latency remains around 12-13 seconds for trivial messages in the observed session.
Frequency: reproduced across multiple live iMessage samples in this local environment.