Skip to content

Hygiene

Agents read your files, run your commands, and write all of it to disk. Hygiene answers two questions: which credentials ended up in those files, and what did a session actually do. It reads transcripts, tool output, edit snapshots, and agent config files. It never shows a credential value, never edits a transcript, and never redacts one. To stay safe after a finding, you rotate the credential at its provider.

Open HygieneSecrets and click Scan now. Use the Agent control to limit the next scan to one agent, and Scan again to refresh.

Each finding is a row: its kind, its label (and key name when there is one), a confidence of high or medium, and how many places, sessions, and files hold it. Click a row to see the places: what kind of text the line is, file:line, and a masked preview.

Hygiene, Secrets section after a scan, with a few findings and the GitHub token one expanded to show its places and masked previewsHygiene, Secrets section after a scan, with a few findings and the GitHub token one expanded to show its places and masked previews
Hygiene, Secrets.

Open in History jumps to the chat that holds the finding.

Every finding carries the same fields in the app, the CLI, and MCP:

  • Kind: what shape matched (see the table below).
  • Label: a short name such as GitHub token, or the key name for a key with a value.
  • Key name: the variable or JSON key next to the value, when there is one.
  • Fingerprint: a short hash of the value. The same credential in many places gets the same fingerprint, so those places form one finding. It is a grouping aid, not a cryptographic digest.
  • Preview: the line around the hit, with the value masked and other secrets redacted.
  • Places: file and line, and whether the line is a prompt, a reply, tool output, a kept file, a config file, or something else.

Confidence has two levels:

Confidence Meaning
high A well-known credential shape: a token with a provider prefix, a private-key block, a JWT, or URL credentials.
medium A sensitive key name with a value that could be a credential, a Bearer value, or a test key.

Exit code 2 and the notification of a scheduled scan both follow high only. Placeholders such as example, your, changeme, or ${VAR} are not reported as key-value findings.

Kind What it matches
Known token Provider prefixes: GitHub, GitLab, Anthropic, OpenAI-style, Slack, AWS, Google, Hugging Face, npm, Stripe (live is high, test is medium), SendGrid. Other recognized prefixes show as API token.
Private key A BEGIN … PRIVATE KEY block.
JWT A JSON Web Token of 40 or more characters.
URL credentials A user and password inside a URL.
Bearer token Bearer followed by 16 or more characters.
Key with value A sensitive key name (such as token, secret, password, api key) with a value that is not a placeholder, written as KEY=value, "key": "value", key: value, or --key value.

After a scan, a finding the app’s scan record had not seen before carries a New mark in HygieneSecrets. The first scan on record is the baseline: nothing in it is new.

Hygiene, Secrets section with one finding marked New next to its confidenceHygiene, Secrets section with one finding marked New next to its confidence
A new finding.

The scan record keeps the fingerprint, kind, confidence, and label of each credential, and counts. It never keeps a value, a preview, a key name, or a path. Only the app writes it. A scan of one agent’s sessions is not recorded.

Open SettingsGeneralHygiene and pick Scheduled secret scan: Off, Every 6 h, Daily, or Weekly. It is off by default. Turn on Notify when a scheduled scan finds new credentials to get a notification.

The notification fires for new high-confidence credentials, never for the first scan, and says a count only, never the credential, a preview, or a path.

Settings, General, Hygiene section with the scheduled secret scan control and the notify switchSettings, General, Hygiene section with the scheduled secret scan control and the notify switch
Settings, Hygiene.

The scan runs in the app, with two threads, a few minutes after launch, and no more often than the interval since the last full scan on record.

The Risks feed lists deletes, root commands, downloads piped into a shell, history rewrites, installs, network calls, secrets files, and work outside the project folder, across every agent and session.

Open HygieneRisks. Narrow it with Window (1 day, 7 days, 30 days), Risk, Agent, and Project. Click a row to open that action in the session’s audit.

Hygiene, Risks section with the 7 days window and a list of flagged actionsHygiene, Risks section with the 7 days window and a list of flagged actions
Hygiene, Risks.

The audit lists what one session did: commands run, files written and read, URLs fetched, and the actions worth a look.

Open HygieneAudit, search the session list by title, prompt, or folder, and pick one. You get Worth a look, Commands, Files written, Files read, URLs, and All actions.

Hygiene, Audit section for one session with Worth a look, Commands, and Files written listsHygiene, Audit section for one session with Worth a look, Commands, and Files written lists
Hygiene, Audit.
  1. Rotate the credential at its provider. A key that sat in a transcript is exposed to anything that can read that file. Revoking it is the only fix.
  2. Remove it from the config file or script it came from.
  3. Optionally move the chat that holds it out of the way (below).

Yardmaster does not edit or redact transcripts. They are vendor files, and purging or redacting one is not implemented.

Move a chat that holds a finding to the Trash

Section titled “Move a chat that holds a finding to the Trash”

In HygieneSecrets, expand a finding and click Archive this chat next to a place, or click Archive all N chats with findings at the top. A dry run opens first: it lists the chats and their sizes. Nothing moves until you click the move button in that review.

Despite the “archive” wording on the buttons (it is stale), the chat moves to your system Trash, through the same planner as Reclaim. Places in config files or outside a chat stay as they are; only whole chats move. A live session or one written to in the last 10 minutes is refused.

Hygiene, Secrets, the dry-run review listing chats to move with the confirm buttonHygiene, Secrets, the dry-run review listing chats to move with the confirm button
The dry run before a chat moves.