> ## Documentation Index
> Fetch the complete documentation index at: https://slopsentral.michne.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Audit Pi and Codex sessions

> Start focused Pi sessions and examine Pi and Codex history.

Use `slopsentral audit` to start a focused Pi session and examine local Pi or Codex history.
Use the [Promptfoo suites](https://slopsentral.michne.com/maintainers/evaluations.md) for scored decisions and execution cases.

## Start a Pi session

Use Pi 1.5.2 and sign in with `pi auth`.
Use the [installed Slopsentral command](https://slopsentral.michne.com/guides/install.md) for these examples.
If the command reports missing audit modules, run `slopsentral self update`.
From a checkout, run `mise exec -- slopsentral audit --help`.
The checkout launcher uses its `uv.toml` and Python version.
Set `UV_CONFIG_FILE` to use your company's uv settings.
Set `UV_SYSTEM_CERTS=true` to use the operating system's certificate store.
See [uv's package index guide](https://docs.astral.sh/uv/concepts/indexes/) for private index settings.

```sh theme={null}
run=$(slopsentral audit run \
  --prompt 'Reply with the word ready.' | jq -r .directory)
slopsentral audit history "$run"
```

The default model is `openai-codex/gpt-6-luna` with low effort.
Use `--model` and `--thinking` to select another model and effort.
Use `--system-prompt FILE` to replace the focused prompt.
Repeat `--context FILE` to append baseline files in order.
Use `--fixture DIR` to copy a directory without symlinks into the workspace.

Repeat `--skill PATH`, `--plugin DIR`, or `--extension PATH` to load specific local resources.
A plugin directory must contain a Pi package manifest.
Use a native package from a Slopsentral Pi projection or installation.
The default tool list contains `read`.
Use `--tools none` for a text-only task.

Pi uses a private configuration directory.
The launcher turns off automatic loading of project instructions, skills, and extensions.
MCP, retries, and compaction also stay off.
The launcher uses the existing Pi login and copies a custom model catalog when one exists.
The launch uses SSE for provider transport.
Pi and its extensions run with local account permissions. Load trusted resources.

Use `--interactive` to open Pi in the terminal.
For a headless run, use `--prompt` or `--prompt-file`.
The headless deadline defaults to 180 seconds.
Use `--timeout` to change it.

The run keeps copied inputs, native sessions, and `run.json` in a private temporary directory.
The report records the requested model, resources, input hashes, elapsed time, and outcome.
Headless runs also keep `stdout.log` and `stderr.log`.
Keep the run directory if you need the evidence after temporary file cleanup.
The files can contain private prompts and tool output.

## Examine local history

```sh theme={null}
slopsentral audit sessions --source codex --limit 5
slopsentral audit sessions --source pi --limit 5
slopsentral audit history "$run" --view context
slopsentral audit history "$run" --view tools --details |
  jq '.events[] | select(.tool == "read")'
```

Pass a session ID, a session file, or an audit directory to `history`.
The command reads local Codex archives with `zstd` when the files use Zstandard compression.
Use `--leaf` with a Pi entry ID to examine a branch.
Pi defaults to the branch that ends at the last persisted entry.

The summary reports event counts, tool outcomes, and token usage.
It covers calls recorded in the transcript.
Codex process receipts contribute their explicit exit status.
Unfinished processes and results without outcome evidence appear as `unknown`.
A call with no matching result appears as `missing`.
Use `--view messages`, `--view usage`, or `--view events` for more detail.
Use `--details` to include selected bodies. Reasoning and binary blocks stay in the native logs.
Use `--after-line` with the returned `nextAfterLine` for the next page.
A page can exceed its limit when one source line produces several events.
If a final line is incomplete, the output reports its number in `incompleteLine`.

## Examine history from Pi

Use `--tools read,bash` if Pi needs to query history.
The launcher puts `slopsentral` on the child process path.
Give Pi a session ID or audit directory in the prompt.
Ask for the summary first.

```sh theme={null}
slopsentral audit run --tools read,bash \
  --prompt "Use slopsentral audit history '$run'. Report the count of successful read calls."
```

## Compare runs

Keep the task, model, effort, tools, and fixture fixed across a control and a plugin run.
Use the context view to examine Pi prompt sections, tool declarations, and custom messages.
Use the tools view to examine the call sequence, arguments, and recorded outcomes.
Compare the task result with an expected result that you define before each run.

Pi and Codex use different input and cache token counters.
The usage view identifies per-response records and cumulative session records.
Pi cost values come from the model catalog. Codex history provides no billed cost.
Treat a single pair as evidence about those runs. Repeat a case to estimate its variability.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.