rootsign is the command you run against recorded sessions: check one, export it as evidence, or approve a tool call that is waiting for a person. It is installed with pip install rootsign. Commands that manage the database or upload the spool are on the operator CLI, rootsign-admin.
Where each command reads from
- A path given with
--localor--checkis read directly. No database and no extras are needed. - A session ID or action ID is looked up in PostgreSQL, at the URL in
DATABASE_URL. This needspip install 'rootsign[postgres]'. These commands use the database whateverROOTSIGN_BACKENDis set to.
.env file in the directory you run the command from.
Exit codes
Each command’s own codes are listed in its section. One rule covers them all: a command-line mistake, such as an unknown option, a mistyped command orrootsign on its own, exits 3. --help exits 0.
For verify, 3 always means nothing was verified, so a script never reads a typing mistake as a verdict.
rootsign version
0.
rootsign verify
A JSONL session file to verify instead, such as
~/.rootsign/sessions/<session_id>.jsonl. A ~ in the path is expanded. Spool files work too.rootsign-admin sync.
Exit codes
Errors
Each prints one line to stderr and exits3:
The database errors were added after RootSign 0.3.1. In 0.3.1 and earlier, an unreachable or uninitialised database printed a traceback and exited
1, the TAMPERED code.rootsign export
manifest.json. With --check, it re-hashes a bundle you received instead. The Export an evidence bundle guide explains what to do with the bundle and the manifest hash.
Re-hash the bundle in this folder against its
manifest.json, and write nothing. When given, every other option is ignored.Which reports to include. The JSON documents and
manifest.json are always written.Leave out the stored content of the session: tool arguments and results, the context shown to an approver, and decision summaries and the alternatives they considered. Hashes, IDs, timings and the verdict are kept.
sync-receipt.json.
Exit codes
To fail a script on a bad session, run
rootsign verify first. export does not exit non-zero for TAMPERED or INCOMPLETE.
Errors
Each prints one line to stderr and exits1:
rootsign approve
@rootsign.trace(require_approval=True). Needs the PostgreSQL backend, because the agent and this command are different processes reading the same store. On the default JSONL backend, approval is a prompt in the agent’s own terminal. Require human approval walks through both.
Reject the action instead of approving it. The tool never runs, and the call raises
HiTLRejectedError in the agent.No pending approvals.
approver_id set to cli: and your operating-system user name, such as cli:alice. RootSign does not authenticate that name: anyone who can reach the database can approve.
Exit codes
Errors
Each prints one line to stderr and exits1:
Related
rootsign-admin
Start the database, create its tables, and upload the spool.
Verify a session
Each verdict’s output, the Python API, and running verify in CI.