Skip to main content

Module paths

Module paths 

Source
Expand description

Path resolution for Pi’s on-disk layout.

Pi stores session logs at:

$HOME/.pi/agent/sessions/--<encoded-cwd>--/<timestamp>_<uuid>.jsonl

The project directory name encodes the cwd: the leading slash is dropped, each remaining / becomes -, and the whole thing is wrapped in --...--. This is lossy for paths that contain internal dashes (Pi has the same limitation), but we accept the ambiguity for now.

Structs§

PathResolver
Resolves the Pi sessions directory and its project subdirectories.

Functions§

decode_project
Decode a Pi project directory name back into a cwd.
encode_project
Encode a cwd path into a Pi project directory name.