pub struct SessionLaunchSettings {
pub language: Option<String>,
pub settings: Option<Value>,
pub agent_progress_summaries: Option<bool>,
pub charter: Option<String>,
pub delegation_preamble: Option<String>,
pub extra_args: Vec<(String, Option<String>)>,
pub force_new: bool,
pub resume_kick: Option<String>,
pub env_overrides: HashMap<String, String>,
}Fields§
§language: Option<String>§settings: Option<Value>§agent_progress_summaries: Option<bool>§charter: Option<String>Charter appended to the spawned claude subprocess’s system
prompt via --append-system-prompt. Set for worker spawns (the
LLM-supplied inline persona, via handle_spawn_worker) and for
lead spawns (the lead charter, via apply_lead_charter); None
only when the caller supplies none.
delegation_preamble: Option<String>Lead-session delegation preamble: when Some, appended to the
system prompt after the forge MCP trust block so a Lead session
knows how to spawn and drive workers. Built by the workspace for
Lead spawns only; None for workers.
extra_args: Vec<(String, Option<String>)>Spawn-path-specific extra CLI args to thread through to the
claude subprocess via OptionsBuilder::extra_arg. Each pair
becomes --<flag> <value> (or --<flag> when the value is
None). Workers in git-repo projects populate
("worktree", Some(label)) so claude forks a worktree at
<repo>/.claude/worktrees/<label>/; lead/resume paths leave
this empty.
force_new: boolBoot-wave fresh-start routing flag (--new). When true, the
project-target spawn arms skip resuming the catalog lead session
and start a fresh one, and the lead cascades it to its workers.
Pure workspace-side routing - #[serde(skip)] keeps it out of
every serialized form, so it never reaches the settings JSON
sent to claude. Defaults false; only the boot dispatch sets it.
resume_kick: Option<String>The first turn a lead receives when this spawn carries a stored
id to resume. The boot wave sets it so a restarted lead continues
without a human prompt; the spawn delivers it only then, so a
first boot or --new sends nothing. A resume the CLI refuses
still takes the note, whose wording does not depend on history.
Pure workspace-side routing - #[serde(skip)] keeps it out of
every serialized form.
env_overrides: HashMap<String, String>Per-spawn env overrides layered over the account env this session spawns under. A present key replaces, an absent key keeps, and a key mapped to an empty string removes the variable. Empty by default, which is exactly the previous behaviour: this is how per-spawn env reaches a respawned child without mutating the previous generation’s Agent.
Implementations§
Source§impl SessionLaunchSettings
impl SessionLaunchSettings
Sourcepub const PERMISSIONS_KEY: &str = "permissions"
pub const PERMISSIONS_KEY: &str = "permissions"
The permissions.defaultMode keys inside settings, shared by
the workspace’s account stamp and the readers here so a rename
cannot split the seam. The settings JSON is forge-internal -
the CLI is driven by argv - so one const per key is the whole
contract.
pub const PERMISSIONS_DEFAULT_MODE_KEY: &str = "defaultMode"
Trait Implementations§
Source§impl Clone for SessionLaunchSettings
impl Clone for SessionLaunchSettings
Source§impl Debug for SessionLaunchSettings
impl Debug for SessionLaunchSettings
Source§impl Default for SessionLaunchSettings
impl Default for SessionLaunchSettings
Source§impl<'de> Deserialize<'de> for SessionLaunchSettings
impl<'de> Deserialize<'de> for SessionLaunchSettings
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for SessionLaunchSettings
Source§impl PartialEq for SessionLaunchSettings
impl PartialEq for SessionLaunchSettings
Source§impl Serialize for SessionLaunchSettings
impl Serialize for SessionLaunchSettings
impl StructuralPartialEq for SessionLaunchSettings
Auto Trait Implementations§
impl Freeze for SessionLaunchSettings
impl RefUnwindSafe for SessionLaunchSettings
impl Send for SessionLaunchSettings
impl Sync for SessionLaunchSettings
impl Unpin for SessionLaunchSettings
impl UnsafeUnpin for SessionLaunchSettings
impl UnwindSafe for SessionLaunchSettings
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.