Spoken Directives Beat Voice Chat
Why voice interfaces for complex software work better as declarative, context-filtered directives than as open-ended conversational chatbots.
When software teams add voice to an application, they usually reach for the same template: a conversational assistant that listens to open-ended speech, sends it to a general-purpose model, and speaks a paragraph back. In a demo, that looks impressive. In daily work, it is mostly friction.
An operator working inside a complex application does not want a conversation with the interface. They want to look at a screen, say "switch to the Acme workspace" or "archive this project," and have the software execute the action cleanly. If the request is ambiguous, the interface should ask a brief, targeted question on screen rather than guessing. If the operator is merely talking about an action—saying "I opened the workspace yesterday" or "don't open anything yet"—nothing should run.
Treating voice as a system of spoken directives rather than voice chat changes the engineering problem from open-ended dialogue to deterministic routing backed by narrow, probabilistic judgment.
Separate Stable Speech From Speculation
Live speech-to-text engines revise their recent words as new audio arrives. Acting on unconfirmed words produces jittery, accidental triggers. A reliable directive system builds strictly on committed, stable transcript text—the words the speech engine will no longer revise—leaving the unconfirmed tail alone until it settles.
Once a trigger term appears in stable text, the system does not immediately call a language model with every action the application supports. Instead, it narrows the field using a live context snapshot sent by the frontend whenever the route, selection, or UI state changes. That snapshot carries two things: boolean flags (such as signedIn or canEditProjects) and current entities (such as currentWorkspace or selectedProject).
Every directive declares an availableWhen list of flags. Availability is evaluated before any model call. An unavailable directive is never offered as an option, which means the judgment layer cannot hallucinate an action the current screen does not support.
Declarative Files Over Embedded Code
A common mistake in agentic UI work is scattering intent-matching logic across frontend components and backend prompts. A cleaner approach is to describe each directive in a single, JSON-serializable data file—never embedding executable functions.
Each file specifies five things: trigger terms, availableWhen flags, a risk tier (read, change, or destructive), ordered parameter steps, and registry keys for backend option lookups (such as "workspaces.search") and frontend handlers (such as "navigation.openWorkspace").
Keeping directives as data yields immediate operational discipline:
- Cross-language loading: A Python speech backend and a TypeScript frontend can share the exact same schema without executing each other's code.
- Load-time validation: When a frontend connects, it sends a
hellomessage listing the handlers present in that build. Any directive referencing a missing lookup or handler is caught at load time rather than failing mid-utterance. - Policy over per-action tuning: Mapping
riskto system-wide confidence thresholds means authors do not hand-tune probability cutoffs per command. Adestructivedirective is structurally required to include a confirmation prompt with resolved parameter labels, such as"Archive Launch plan in Acme?".
Bounded Judgment, Not Free-Form Extraction
Instead of asking a generative model to invent function calls, the backend sends the utterance window, the current context snapshot, and the narrowed candidate list to a typed judgment model. The model answers a closed choice question—one label per candidate directive, plus an explicit none option for negation, quoting, or past-tense remarks—returning probabilities and a confidence score.
Required parameters are resolved the same way, using options returned by permission-scoped backend lookups. When a step is unspecified or unclear, the system opens a pending directive record, tracks the exact word index range already consumed so no phrase fires twice, and displays a concise on-screen prompt. The operator can resolve it by speaking a short reply or simply clicking the option.
Good operator tooling respects attention. By constraining voice to declarative files, live UI context, and bounded choice questions, speech stops competing with the screen and starts working like a fast, dependable keyboard shortcut.
Join the PathGuided Closed Beta
Onboard your repositories with local-to-cloud spec execution, split-tier model routing, and commit-bound Work Tours.