Skip to content

[codex] Preserve full chat text for Tray TTS#900

Draft
ArtLupo wants to merge 1 commit into
openclaw:mainfrom
ArtLupo:codex/tray-tts-full-message
Draft

[codex] Preserve full chat text for Tray TTS#900
ArtLupo wants to merge 1 commit into
openclaw:mainfrom
ArtLupo:codex/tray-tts-full-message

Conversation

@ArtLupo

@ArtLupo ArtLupo commented Jul 1, 2026

Copy link
Copy Markdown

Summary

  • preserve the untruncated assistant chat response on OpenClawNotification.FullMessage
  • keep the existing 200-character notification preview in Message
  • make Tray TTS prefer FullMessage while falling back to Message
  • add a regression test that verifies preview truncation and full-message preservation

Why

Tray read-aloud currently uses the same notification preview text that is truncated for toast/history display, so long assistant responses stop around the preview boundary.

Validation

  • dotnet test tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj -c Release --filter FullyQualifiedName~OpenClawGatewayClientTests
  • dotnet test tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj -c Release

@clawsweeper

clawsweeper Bot commented Jul 1, 2026

Copy link
Copy Markdown

Codex review: needs real behavior proof before merge. Reviewed July 1, 2026, 2:41 AM ET / 06:41 UTC.

Summary
The PR adds OpenClawNotification.FullMessage, preserves the truncated Message preview, makes Tray TTS prefer the full text, and adds a shared gateway-client regression test.

Reproducibility: yes. from source inspection: current main truncates assistant notification text at 200 characters and Tray TTS reads that same preview field. I did not run a live Windows tray reproduction in this read-only review.

Review metrics: 2 noteworthy metrics.

  • Changed surface: 4 files changed, 36 additions, 1 deletion. The PR is small but crosses shared models, gateway parsing, Tray UI side effects, and regression tests.
  • Required validation reported: 0 of 3 required policy commands reported; 2 focused commands reported. AGENTS.md requires full build plus shared and tray test commands before completion, while the PR body lists only focused validation.

Merge readiness
Overall: 🦪 silver shellfish
Proof: 🧂 unranked krab
Patch quality: 🐚 platinum hermit
Result: blocked until real behavior proof is added.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Rank-up moves:

  • [P1] Add a ## Real behavior proof section with current-head redacted evidence that Tray read-aloud speaks a long assistant response past the 200-character preview boundary.
  • [P1] Report the repository-required ./build.ps1, full shared test, and tray test validation commands from AGENTS.md.

Proof guidance:

  • [P1] Needs real behavior proof before merge: The PR body has automated test commands but no after-change proof from a real tray read-aloud run; add redacted screenshot/video, terminal or live output, or runtime logs showing the long response is spoken, and redact IPs, API keys, phone numbers, private endpoints, and other private details before posting. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.

Mantis proof suggestion
A visible or logged tray read-aloud proof would materially help reviewers verify the user-facing behavior. A maintainer can ask Mantis to capture proof by posting this exact PR comment:

@openclaw-mantis visual task: verify Tray read-aloud speaks a long assistant response past the 200-character notification preview boundary.

Risk before merge

  • [P1] The PR body reports only targeted test commands, not the repository-required ./build.ps1, full shared tests, and tray tests from AGENTS.md.
  • [P1] The PR body has no after-change real behavior proof showing a long assistant response being spoken past the notification preview boundary in the Tray read-aloud path.

Maintainer options:

  1. Decide the mitigation before merge
    Land the narrow preview/full-text split only after required validation and current-head tray read-aloud proof, while keeping toast, history, activity, and categorization surfaces on the existing preview text.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Next step before merge

  • [P1] The remaining blockers are contributor-side real behavior proof, required validation reporting, and normal maintainer review rather than a concrete repair ClawSweeper can safely supply.

Security
Cleared: No concrete security or supply-chain issue was found; source inspection keeps logs, notification history, and app notification mapping on the preview field rather than the new full text.

Review details

Best possible solution:

Land the narrow preview/full-text split only after required validation and current-head tray read-aloud proof, while keeping toast, history, activity, and categorization surfaces on the existing preview text.

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

Yes from source inspection: current main truncates assistant notification text at 200 characters and Tray TTS reads that same preview field. I did not run a live Windows tray reproduction in this read-only review.

Is this the best way to solve the issue?

Yes, the proposed split is the narrow maintainable direction as long as full text stays limited to the TTS path and preview text remains the toast/history/categorization source.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 4166e0fd63f8.

Label changes

Label changes:

  • add P2: This is a normal user-facing Tray TTS bug fix with limited blast radius.
  • add rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🧂 unranked krab and patch quality is 🐚 platinum hermit.
  • add status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask. Needs real behavior proof before merge: The PR body has automated test commands but no after-change proof from a real tray read-aloud run; add redacted screenshot/video, terminal or live output, or runtime logs showing the long response is spoken, and redact IPs, API keys, phone numbers, private endpoints, and other private details before posting. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.

Label justifications:

  • P2: This is a normal user-facing Tray TTS bug fix with limited blast radius.
  • rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🧂 unranked krab and patch quality is 🐚 platinum hermit.
  • status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask. Needs real behavior proof before merge: The PR body has automated test commands but no after-change proof from a real tray read-aloud run; add redacted screenshot/video, terminal or live output, or runtime logs showing the long response is spoken, and redact IPs, API keys, phone numbers, private endpoints, and other private details before posting. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
Evidence reviewed

Acceptance criteria:

  • [P1] ./build.ps1.
  • [P1] dotnet test ./tests/OpenClaw.Shared.Tests/OpenClaw.Shared.Tests.csproj --no-restore.
  • [P1] dotnet test ./tests/OpenClaw.Tray.Tests/OpenClaw.Tray.Tests.csproj --no-restore.

What I checked:

  • Repository policy read: The target AGENTS.md was read fully; tray/chat changes require the full build, shared tests, tray tests, and current-head visible proof or a blocker. (AGENTS.md:1, 4166e0fd63f8)
  • Current main truncates chat notification text: EmitChatNotification builds a 200-character displayText and assigns that preview to OpenClawNotification.Message. (src/OpenClaw.Shared/OpenClawGatewayClient.cs:3247, 4166e0fd63f8)
  • Current main speaks the preview field: Tray notification handling calls SpeakResponseAsync(notification.Message), so read-aloud uses the truncated preview on current main. (src/OpenClaw.Tray.WinUI/App.xaml.cs:2695, 4166e0fd63f8)
  • Latest release has the same behavior: v0.6.12 points at the checked-out main commit, so the latest release still contains the current truncation/TTS path. (4166e0fd63f8)
  • PR diff is narrow and targeted: The diff adds one nullable model property, populates it from the untruncated assistant text, uses it for Tray TTS fallback, and adds a regression test for full-message preservation. (src/OpenClaw.Tray.WinUI/App.xaml.cs:2672, 61b84946ed10)
  • PR body lacks real behavior proof: The PR body lists two test commands but no ## Real behavior proof section or runtime evidence for a real tray read-aloud run. (61b84946ed10)

Likely related people:

  • shanselman: Local blame in the grafted checkout points the touched current-main lines to the v0.6.12 release snapshot, and GitHub history shows recent App.xaml.cs guardrail work by shanselman. (role: current-main release snapshot and recent App-area contributor; confidence: medium; commits: 4166e0fd63f8, 06b63ac6ce7d; files: src/OpenClaw.Tray.WinUI/App.xaml.cs, src/OpenClaw.Shared/OpenClawGatewayClient.cs, src/OpenClaw.Shared/Models.cs)
  • TurboTheTurtle: GitHub history shows recent adjacent work on assistant chat event filtering and gateway-client tests in the same receive/notification area. (role: recent gateway chat contributor; confidence: medium; commits: 65b88d8b639f; files: src/OpenClaw.Shared/OpenClawGatewayClient.cs, tests/OpenClaw.Shared.Tests/OpenClawGatewayClientTests.cs)
  • RBrid: GitHub history shows recent work mirroring gateway notifications into in-app notifications through App.xaml.cs and AppNotificationMapper, adjacent to the preview/history boundary this PR preserves. (role: recent tray notification contributor; confidence: medium; commits: 8b5ea3294b33; files: src/OpenClaw.Tray.WinUI/App.xaml.cs, src/OpenClaw.Tray.WinUI/Services/AppNotificationMapper.cs)
  • bkudiess: GitHub history shows multiple recent commits touching OpenClawGatewayClient.cs and App.xaml.cs around chat model selection, session controls, diagnostics, and tray state. (role: recent chat and tray area contributor; confidence: medium; commits: d6b1a72f6d23, 989f9ffde2dd; files: src/OpenClaw.Shared/OpenClawGatewayClient.cs, src/OpenClaw.Tray.WinUI/App.xaml.cs)
What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

How this review workflow works
  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@clawsweeper clawsweeper Bot added rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. P2 Normal priority bug or improvement with limited blast radius. labels Jul 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P2 Normal priority bug or improvement with limited blast radius. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant