--- name: troubleshooting namespace: user description: >- Ralphy CLI operations and repair — environment setup, API keys and connectors, `ralphy doctor`, reading logs, diagnosing a failed generation or render, and the CLI cookbook for verbs other roles call. USE WHEN the user says "set this up", "set up my keys", "run ralphy doctor", "nothing works", "it failed", "read the logs", "missing key", "why did this generation fail", or asks any question about how a `ralphy` verb works. TRIGGER (EN): "doctor", "nothing works", "set up keys", "read the logs", "debug this failure", "missing API key", "how do I run ". --- # Troubleshooting playbook **Read this when:** "set up", "set up keys", "ralphy doctor", "nothing works", "read logs", "debug failed generation", "missing key", any ralphy CLI usage question. Plumbing role. Other roles call me when something breaks, when the environment isn't up, or when the user wants to inspect under the hood. Ops + CLI expert layer beneath the creative roles. > **STOP rule.** Every observability question is a `ralphy` verb. Don't `cat` / `tail` JSONL by hand — the log readers below sort, merge, and filter for you. AGENTS invariant #2. ## CLI cookbook **Every observability question is a `ralphy` verb. Don't `cat` JSONL by hand — the log readers below sort, merge, and filter for you.** ```bash # Env / setup health ralphy doctor # full env check (keys, deps, project) ralphy doctor -p # human-readable ralphy status # capabilities + linked project ralphy setup # interactive wizard (first-time keys) ralphy config get / set # config CRUD # Logs (per-project, append-only via cli/lib/gen-log.ts) ralphy project log --type generations --limit 50 # latest model calls + cost + errors ralphy project log --type user-prompts --limit 20 # what the user said, when ralphy project log --type user-assets --limit 20 # what the user uploaded ralphy project log --type all --limit 200 # merged, chronological JSON ralphy project timeline # pretty chronological log (table) # Workspace inspection ralphy workspace stats # cross-project counts + disk usage ralphy project list -p # status per project ralphy assets list # ralphy-assets companion repo ralphy assets cache-info # local SHA-verified cache ralphy assets pull