fix: accept leading fuzzy Discord voice wake names#86484
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed May 25, 2026, 8:54 AM ET / 12:54 UTC. Summary PR surface: Source +157, Tests +127, Docs +1. Total +285 across 3 files. Reproducibility: yes. From the patch source, a transcript like Review metrics: 2 noteworthy metrics.
Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance: Mantis proof suggestion Risk before merge
Maintainer options:
Copy recommended automerge instructionNext step before merge Security Review findings
Review detailsBest possible solution: Keep the fuzzy wake-name behavior, but tighten the distance-two case and add a regression for common ambient false positives before merging with live Discord voice proof. Do we have a high-confidence way to reproduce the issue? Yes. From the patch source, a transcript like Is this the best way to solve the issue? No, not as currently written. The owner path is right, but the fuzzy threshold needs to preserve the wake gate for common ambient words while still accepting the intended ASR variants. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model gpt-5.5, reasoning high; reviewed against fcf0bff92965. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +157, Tests +127, Docs +1. Total +285 across 3 files. View PR surface stats
Acceptance criteria:
What I checked:
Likely related people:
What the crustacean ranks mean
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
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5aa284b6d1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const distance = levenshteinDistance(heardCompact, wakeCompact); | ||
| if (distance <= 1) { | ||
| return true; | ||
| } | ||
| return distance === 2 && wakeCompact.length >= 5 && heardCompact.length !== wakeCompact.length; |
There was a problem hiding this comment.
Tighten fuzzy wake matching to avoid prepended-word triggers
leadingWakeNameCandidates can include multiple leading words, but isFuzzyWakeNameMatch accepts any candidate within edit distance 1 (or 2 with length mismatch). That lets non-address phrases like "an open claw, ..." match the default openclaw wake name (anopenclaw vs openclaw distance 2), so requireWakeName can be bypassed and an agent consult can fire on ambient speech. The fuzzy check should reject candidates that differ by full extra tokens/prefixes rather than minor ASR misspellings.
Useful? React with 👍 / 👎.
|
ClawSweeper PR egg 🎁 Pass real behavior proof to wake the egg and unlock a hatchable treat. Where did the egg go?
|
|
Verification before merge: Local proof:
CI proof:
Known proof gaps:
|
Summary
requireWakeNameis enabled.MontyandMotifor aMoltywake name only at the start of an utterance.Open law is...orMulti, ...stay gated.Verification
pnpm test extensions/discord/src/voice/manager.e2e.test.ts -- --reporter=verboseenv -u OPENCLAW_TESTBOX pnpm check:changed.agents/skills/autoreview/scripts/autoreview --mode localReal behavior proof
Behavior addressed: Discord OpenAI realtime voice wake-name gating now accepts leading ASR variants for the routed agent name without requiring config aliases.
Real environment tested: local OpenClaw source checkout with Discord voice manager E2E tests and changed extension checks.
Exact steps or command run after this patch:
pnpm test extensions/discord/src/voice/manager.e2e.test.ts -- --reporter=verbose;env -u OPENCLAW_TESTBOX pnpm check:changed;.agents/skills/autoreview/scripts/autoreview --mode local.Evidence after fix: the Discord voice E2E suite passes 113 tests, including new coverage for
Monty,Moti,Open claw,Multi, ..., andOpen law is...wake-gate behavior.Observed result after fix: leading fuzzy wake phrases are stripped before agent consults; non-wake and ambient leading phrases do not call the agent.
What was not tested: live Discord voice audio against the remote gateway was not rerun for this PR; tmux inspection before the patch showed the failing transcripts and exact
OpenClawsuccess path.