psychology-agent: Skill for Claude Code

.claude/skills/diagnose/SKILL.md

diagnose is a skill for Claude Code from safety-quotient-lab/psychology-agent. It costs 19 tokens per session (4,178 once invoked), scanned A, original, Apache-2.0.

A five-level self-diagnostic skill for checking the psychology-agent project's health, from a quick status snapshot to a thorough cross-system analysis.

In plain words
What is it for?
Checking subsystem health, reviewing metrics and findings, detecting drift, and analyzing alignment across project systems.
Why use it?
It replaces ad-hoc manual checking with a consistent way to investigate problems at the needed depth.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: reads .claude/ paths; mentions CLAUDE.md; positional $N argument.

This is safety-quotient-lab/psychology-agent's own configuration. It tells Claude Code how to work on psychology-agent itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything psychology-agent configures →

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is python3 scripts/dual_write.py --help 2>&1 | grep -oE '\{[^}]+\}' | head -1.

Reuse

Borrowing it

Nothing to install: this file belongs to safety-quotient-lab/psychology-agent. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/safety-quotient-lab/psychology-agent/main/.claude/skills/diagnose/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/safety-quotient-lab/psychology-agent

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for diagnose

README.md
[![agentmods](https://agentmods.dev/badge/skills/safety-quotient-lab/psychology-agent/diagnose/github.svg)](https://agentmods.dev/skills/safety-quotient-lab/psychology-agent/diagnose)
Your own site
<a href="https://agentmods.dev/skills/safety-quotient-lab/psychology-agent/diagnose"><img src="https://agentmods.dev/badge/skills/safety-quotient-lab/psychology-agent/diagnose/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for diagnose

Your own site · 80×15
<a href="https://agentmods.dev/skills/safety-quotient-lab/psychology-agent/diagnose"><img src="https://agentmods.dev/badge/skills/safety-quotient-lab/psychology-agent/diagnose.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 19 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,178 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00019 $0.04178
Opus 5.5 $0.00008 $0.01671
Sonnet 5.5 $0.00004 $0.00836
Haiku 4.5 $0.00002 $0.00418

Measured 2mo ago against content hash 3aaf51962452, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

diagnose scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/diagnose/SKILL.md · 503 lines

How it starts

The opening of the file, as written. The whole thing — 503 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/diagnose — Systemic Self-Diagnostic

Five-level diagnostic hierarchy for the psychology agent cogarch. Higher numbers run faster with less depth; lower numbers run slower with more thoroughness. Level 1 replaces manual QA.

Design reference: five-tier diagnostic depth model adapted from the structured diagnostic protocol in Sternbach & Okuda (1991), Star Trek: The Next Generation Technical Manual. Level 1 requires the most resources and produces the most complete picture; Level 5 produces a status snapshot with minimal overhead. The key design insight from that reference: lower diagnostic numbers indicate higher thoroughness, not lower priority — a convention this system adopts.


Diagnostic Levels

Level Scope Depth Systems Affected Estimated Duration
5 Status poll Row counts, binary health indicators None — read-only ~10 seconds
4 Targeted subsystem Detail queries for one subsystem None — read-only ~30 seconds
3 Standard sweep All subsystems, key metrics, findings None — read-only ~2 minutes
2 Cross-system analysis L3 + drift detection, alignment checks, pattern analysis None — read-only ~5 minutes
1 Full integrity verification L2 + file checks, governance verification, hook validation, CLI tests, orphan detection Writes test records (cleaned up) ~10 minutes

Default: Level 3.

Usage:

/diagnose          — Level 3, all subsystems
/diagnose 5        — Level 5, status poll
/diagnose 4 claims — Level 4, claims subsystem deep scan
/diagnose 1        — Level 1, full integrity verification (replaces manual QA)

Recommended cadence:

Level When
5 Session start — quick pulse before work begins
4 When a specific subsystem shows degraded status
3 Every 5-10 sessions; after /cycle as health check
2 After schema migrations, bootstrap rebuilds, infrastructure changes
1 After major refactors; before release tags; after long idle periods

Read the full file on GitHub · 503 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 503 lines · 19 tokens per session scan A 3aaf51962452

Subscribe to this mod's changes

diagnose is a skill published in the GitHub repository safety-quotient-lab/psychology-agent (23 stars, last pushed 6mo ago), licensed Apache-2.0. It adds 19 tokens to every session and 4,178 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

diagnose compared with skills from other repositories

diagnose next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
diagnosesafety-quotient-lab/psychology-agentSkill236mo agoApache-2.0A19Claude Code
systematic-debuggingopen-metadata/OpenMetadataSkill16kyesterdayApache-2.0A37Claude Code
log-error-digestzebbern/claude-code-guideSkill4.7k3d agoMITA71Claude Code, Codex
cwv-optimizeradobe/skillsSkill319yesterdayApache-2.0A112Claude Code
ci-fixersipyourdrink-ltd/bernsteinSkill1.2kyesterdayApache-2.0A15Claude Code, Codex
triaging-web-analytics-supportPostHog/posthogSkill41kyesterdaynoneA151Claude Code, Codex
diagnosing-missing-recordingsPostHog/posthogSkill41kyesterdaynoneA76Claude Code, Codex