pub struct Config {Show 30 fields
pub cwd: PathBuf,
pub home: PathBuf,
pub agent_dir: PathBuf,
pub settings: Value,
pub loki: LokiMode,
pub loki_hygiene: Level,
pub loki_root: Option<PathBuf>,
pub runtime_path: PathBuf,
pub skills_dir: PathBuf,
pub mask_secrets: Option<String>,
pub output_bytes: Option<String>,
pub cell_yield_after: Option<String>,
pub snapshot_key: Option<Vec<u8>>,
pub spawn_depth: u32,
pub async_events: bool,
pub ts_guide: bool,
pub hints: bool,
pub turn_guards: bool,
pub result_footer: bool,
pub tool_rounds_nudge: u64,
pub skill_nudge: u64,
pub context_images: usize,
pub frame_env: HashMap<String, String>,
pub var: VarLookup,
pub masker: Arc<OutputMasker>,
pub project_trusted: bool,
pub provider_token: ProviderToken,
pub outside_changes: OutsideChanges,
pub lsp: Option<LspGuard>,
pub terminal_theme: Arc<Mutex<Option<String>>>,
}Expand description
What every lane of this process shares: settings, locations, guards and the snapshot key. Owned values only, so subagent lanes can be built on their own threads.
Fields§
§cwd: PathBuf§home: PathBuf§agent_dir: PathBuf§settings: ValueThe merged settings (sandbox.*, loki, …).
loki: LokiMode§loki_hygiene: LevelWhich hygiene advisories Loki adds after a write (ULTRON_LOKI_HYGIENE, else loki.hygiene, else on).
loki_root: Option<PathBuf>Where Loki’s policy is read: the Git work tree containing the cwd, else the cwd (None when Loki is off).
runtime_path: PathBuf§skills_dir: PathBuf§mask_secrets: Option<String>§output_bytes: Option<String>§cell_yield_after: Option<String>ULTRON_CELL_YIELD_AFTER: how long a woken root’s cell may hold its tool call before it continues in the
background (crate::lane cell_yield_after).
snapshot_key: Option<Vec<u8>>§spawn_depth: u32§async_events: boolULTRON_ASYNC_EVENTS is not off: completions of detached work continue the run.
ts_guide: boolULTRON_GUIDE=ts (ts_guide).
hints: boolULTRON_HINTS=on (hints).
turn_guards: boolNot ULTRON_TURN_GUARDS=off, outside the TypeScript guide (turn_guards).
The global rlm.resultFooter setting, outside the TypeScript guide: REPL results end with
crate::lane::result_footers, and the runtime guide says so.
tool_rounds_nudge: u64Rounds without a user message before the root is nudged (ULTRON_TOOL_ROUNDS_NUDGE).
skill_nudge: u64Turns before a skill-extraction nudge (ULTRON_SKILL_NUDGE).
context_images: usizeTool-result images a request keeps (ULTRON_CONTEXT_IMAGES; 0: all).
frame_env: HashMap<String, String>The frame settings rlm.map / rlm.infer read from the environment (ULTRON_RLM_FRAME_MODEL,
ULTRON_REVIEW_MODEL, ULTRON_RLM_MAP_TOKENS).
var: VarLookupThe process environment, for models.json keys and headers ($VAR values).
masker: Arc<OutputMasker>Cell output masking for every lane: the values MCP servers resolve (env, headers) are registered here, as
TypeScript’s process-wide registerSecretValues.
project_trusted: boolWhether the project’s own configuration (.pi/mcp.json) may be read.
provider_token: ProviderTokenThe current key of a /login provider, for MCP servers with auth.provider.
outside_changes: OutsideChangesFiles Loki’s own setup commit changed (crate::loki_notice): not the changes of the cell it ran beside.
lsp: Option<LspGuard>The session’s language servers, shared by every lane; None when they are off (lsp::enabled).
terminal_theme: Arc<Mutex<Option<String>>>The terminal appearance the attached TUI reported (crate::core::Op::SetTerminalTheme): diagram.mermaid’s
auto theme follows it before the session’s COLORFGBG.
Implementations§
Source§impl Config
impl Config
pub fn child_env(&self) -> Vec<(String, String)>
Sourcepub fn settings_reader(&self) -> Arc<dyn Fn() -> SettingsManager + Send + Sync> ⓘ
pub fn settings_reader(&self) -> Arc<dyn Fn() -> SettingsManager + Send + Sync> ⓘ
Reads the settings as they are now, with the worker’s project trust (fixed when the session opened): what the
TypeScript worker reads from its live SettingsManager per frame, spawn or request.
Sourcepub fn bundled_skills(&self) -> Option<String>
pub fn bundled_skills(&self) -> Option<String>
The bundled skills directory (packages/coding-agent/skills, beside the runtime), unless
ULTRON_BUNDLED_SKILLS turns it off.
Sourcepub fn mcp_gateway(&self) -> Arc<Gateway> ⓘ
pub fn mcp_gateway(&self) -> Arc<Gateway> ⓘ
The session’s MCP gateway (TypeScript’s extensions/mcp, built in): the servers of mcp.json, and of .pi/mcp.json in a trusted
project, reached from the REPL through the mcp tool. Server log messages go to <agentDir>/mcp.log.
Sourcepub fn model(&self, provider: &str, id: &str) -> Option<Model>
pub fn model(&self, provider: &str, id: &str) -> Option<Model>
The model provider/id of the built-in catalog or models.json, ready for requests.
Sourcepub fn find_models(&self) -> Value
pub fn find_models(&self) -> Value
rlm.find_models (session-worker.ts): the available models (registry.getAvailable()) as
{provider, id, name}, whatever the query.
Sourcepub fn race_models(&self) -> Value
pub fn race_models(&self) -> Value
rlm.race_models: rlm.raceModels (/settings -> Models) read now, keeping the refs that name a known model.