Repository navigation
refactor: make Talk consultation aliases private - #184732
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. What this changesThis PR makes three unused Talk consultation type aliases private without changing their definitions or runtime behavior. Example: A Talk consultation uses GatewayControlOwner.runAgentConsult.
Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review This PR is a correct, minimal internal cleanup with no actionable findings; the reviewed head passes the CI gate. Priority: P3 Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherGateway Talk control connects voice-provider requests to agent consultations; this module defines the internal lifecycle and callback types used by those owners. flowchart LR
A[Talk provider request] --> B[Gateway control owner]
C[Consultation types] -.-> B
C -.-> D[Agent consultation]
B --> D
D --> E[Provider response]
Technical reviewBest possible solution: Keep these owner-local aliases private while preserving the exported consumer contracts. Do we have a high-confidence way to reproduce the issue? There is no runtime bug to reproduce; source inspection confirms that the three exported names have no consumers outside their owner module. Is this the best way to solve the issue? Removing only the export modifiers is the smallest complete change: it narrows visibility without duplicating types, changing structural contracts, or adding test scaffolding. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 3fe7f1e2a43c. Provenance checked
SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource 0. Total 0 across 1 file. Added test files: 0. View PR surface stats
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 26, 2026, 11:07 AM ET / 15:07 UTC. |
|
Simplified: Talk consultation helper aliases are now private while the existing Gateway owner and options contracts remain unchanged. |
Keep the three owner-local Talk consultation aliases private while preserving the existing Gateway owner and options contracts and runtime behavior.
What Problem This Solves
OpenClaw's unused-export inventory reports three Talk consultation type aliases that are exported from their owner module even though no supported caller imports or names them. Keeping owner-local implementation types exportable leaves the static contract broader than its actual consumers and prevents the export inventory from converging on the supported surface.
User Impact
There is no user-visible behavior change. The existing
GatewayControlOwnerandTalkClientGatewayControlOptionscontracts retain the same fields and nested function shapes, and Talk consultation authority, cancellation, steering, completion, recovery, and teardown behavior remain unchanged. No public API, Plugin SDK entrypoint, manifest, protocol, configuration, or persisted data shape changes.Why This Change Was Made
The three aliases are used only to compose exported types in
client-agent-consult.types.ts; repository-wide inspection found no imports or re-exports of their names. This change removes only theirexportmodifiers while preserving every alias body and every other export. Because these are type-only declarations, the runtime output is unchanged.Evidence
d777ae1239625a8cadb3da17e7a057d0c4de71fafound the three names only in their declaring module and found no supported package, Plugin SDK, manifest, protocol, namespace, test, or documentation exposure.