产品介绍

Path resolution and session bindings

This page covers path resolution, initialization permissions, and workspace boundaries maintained by developers. To locate configuration, logs, databases, or traces, start with the operational Home directory and files guide. See session records and SQLite for database inspection.

Directory layout

The runtime uses one Home, defaulting to ~/.dataagent, selected through DATAAGENT_HOME in the process environment. Relative paths resolve against the launch working directory. Resolving a path does not create files. See configuration fields and environment variables for configuration and environment-file selection. The complete tree and file purposes have one owner: the operational Home overview.

Implementation entry Contract maintained
home_path, RuntimePaths Home location, workspace validation, state-directory and default-output-root resolution
SessionPaths, open_session in the same file Separate session state in Home from independently located outputs; register and reuse session bindings
initialize_home, ensure_session in the same file Explicit Home-template initialization and directory creation when a session first opens
Sessions Backend session index and run status; see state and storage for tables and their relationship to the checkpointer

serve and serve-a2a initialize missing Home directories and templates by default; history-sql does not initialize the full template set. SDK callers can opt in through LaunchOptions(init_home=True). An explicit configuration file skips initialization of Home config.yaml. New directories use 0700, templates use 0600, and existing files are preserved unchanged. See state and storage for runtime and output-directory permissions.

See bootstrap and extension lifecycle for resource location and loading order.

Workspaces and sessions

Workspaces are input directories selected through dataagent.input_workspaces in the chosen YAML. A directory must exist and the process must be able to read and enter it. Its logical name does not become a path component. See inputs and workspaces for usage and sessions and outputs for bindings during recovery.

Runtime state lives in Home runtime/; session outputs live in separate business directories. File tools and shell use the host process's OS permissions, with the session output directory as their default working directory. Security boundaries explain the separate roles of application path checks and OS permissions.