Skip to main content

Module launch_settings

Module launch_settings 

Source
Expand description

The settings a session is spawned with.

Read from the three Claude Code documents rather than kept as state, so a session started from a client spawns with what the CLI itself would have launched. A spawn that skipped this carries no language and no model, and the CLI’s own defaults for permissions, effort and output style.

Re-exportsΒ§

use forge_agent::client::SessionLaunchSettings; πŸ”’
use forge_primitives::runtime::EffortLevel; πŸ”’
use serde_json::Map; πŸ”’
use serde_json::Value; πŸ”’
use serde_json::json; πŸ”’

StructsΒ§

LaunchSettingsDocuments
The three documents a launch reads, each as the CLI sees it.

EnumsΒ§

DefaultPermissionMode
The mode stored at settings.permissions.defaultMode.
OutputStyle
The style stored at settings.outputStyle.

ConstantsΒ§

LANGUAGE_MAX_CHARS πŸ”’
LANGUAGE_MIN_CHARS πŸ”’

FunctionsΒ§

always_thinking_enabled
build_session_settings_object πŸ”’
default_permission_mode
Forge defaults to Auto, which the CLI itself calls default.
language
The language a session is launched in, when the stored value is usable.
language_input_validation_message
Validate a free-text language string before it reaches the launch settings payload. Returns a message when the value is out of range, otherwise None for β€œlooks fine”.
model
The model a session launches on. Forge defaults to opus when none is stored; the CLI’s own default is sonnet, so without this every fresh forge session would launch on sonnet.
output_style
read_bool πŸ”’
read_json_path πŸ”’
read_string πŸ”’
session_launch_settings
The settings a launch carries: the language, the settings object the CLI merges at boot, and agent progress summaries.
spinner_tips_enabled
terminal_progress_bar_enabled
thinking_effort
Forge defaults to max effort when none is stored.