pub struct MuseExecBuilder { /* private fields */ }Expand description
Builder for one muse exec --json invocation.
Implementations§
Source§impl MuseExecBuilder
impl MuseExecBuilder
pub fn new(prompt: impl Into<String>) -> Self
Sourcepub fn binary(self, path: impl Into<String>) -> Self
pub fn binary(self, path: impl Into<String>) -> Self
Use a specific binary instead of muse from PATH.
pub fn provider(self, provider: Provider) -> Self
Sourcepub fn preset(self, preset: impl Into<String>) -> Self
pub fn preset(self, preset: impl Into<String>) -> Self
Built-in preset (native-basic, miniswe).
pub fn model(self, model: impl Into<String>) -> Self
Sourcepub fn session_id(self, session_id: impl Into<String>) -> Self
pub fn session_id(self, session_id: impl Into<String>) -> Self
Run under a caller-supplied session id (--session-id), the basis of
multi-turn continuity: each turn is its own process, and passing the
same id makes the CLI continue that session rather than start a new
one. The id is adopted verbatim as the stream.id on every emitted
record.
Supplying your own id is also what makes
MuseRecord identity safe to key on: record
ids are UUID-shaped counters that repeat across sessions, so the
only unique handle is the composite (stream.id, id) — and that is
trustworthy precisely because stream.id is yours. (When omitted,
the CLI mints a random v4 of its own.)
Sourcepub fn reasoning_effort(self, effort: impl Into<String>) -> Self
pub fn reasoning_effort(self, effort: impl Into<String>) -> Self
Meta reasoning effort (none|minimal|low|medium|high|xhigh|ultra).
Not supported with Provider::Echo.
pub fn base_url(self, url: impl Into<String>) -> Self
pub fn working_directory(self, dir: impl Into<PathBuf>) -> Self
pub fn env(self, key: impl Into<String>, value: impl Into<String>) -> Self
Sourcepub fn build_command(&self) -> Result<Command>
pub fn build_command(&self) -> Result<Command>
Resolve the binary and assemble the command with piped stdio.
Trait Implementations§
Source§impl Clone for MuseExecBuilder
impl Clone for MuseExecBuilder
Source§fn clone(&self) -> MuseExecBuilder
fn clone(&self) -> MuseExecBuilder
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more