[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-909":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":15,"forks30d":15,"starsTrendScore":19,"compositeScore":20,"rankGlobal":10,"rankLanguage":10,"license":10,"archived":21,"fork":21,"defaultBranch":22,"hasWiki":21,"hasPages":21,"topics":23,"createdAt":10,"pushedAt":10,"updatedAt":27,"readmeContent":28,"aiSummary":29,"trendingCount":15,"starSnapshotCount":15,"syncStatus":16,"lastSyncTime":30,"discoverSource":31},909,"claude-doctor","millionco\u002Fclaude-doctor","millionco","Diagnose your Claude Code sessions","",null,"TypeScript",585,49,1,0,2,3,15,6,9.1,false,"main",[24,25,26],"claude","code","doctor","2026-06-12 02:00:20","# claude-doctor\n\nAnalyzes your `~\u002F.claude\u002F` transcripts for behavioral anti-patterns and generates rules for CLAUDE.md \u002F AGENTS.md from your history.\n\nhttps:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002Fcdeb6b05-f3e6-441b-8bc2-9fcce623d9fd\n\n## Install\n\n```bash\nnpm i -g claude-doctor\n```\n\nOr run directly:\n\n```bash\nnpx claude-doctor\n```\n\n## Usage\n\n```bash\nclaude-doctor                     # analyze all sessions (default)\nclaude-doctor \u003Csession-id>        # check a specific session\nclaude-doctor \u003Cpath\u002Fto.jsonl>     # check a specific session file\nclaude-doctor -p myproject        # filter to a project\nclaude-doctor --rules             # generate rules for CLAUDE.md \u002F AGENTS.md\nclaude-doctor --save              # save model to .claude-doctor\u002F\nclaude-doctor --json              # output as JSON\n```\n\n## Signals\n\n### Structural\n\n| Signal | Detection |\n|---|---|\n| `edit-thrashing` | Same file edited 5+ times in one session |\n| `error-loop` | 3+ consecutive tool failures without changing approach |\n| `excessive-exploration` | Read-to-edit ratio above 10:1 |\n| `restart-cluster` | Multiple sessions started within 30 minutes |\n| `high-abandonment-rate` | Most sessions have fewer than 3 user messages |\n\n### Behavioral\n\n| Signal | Detection |\n|---|---|\n| `correction-heavy` | 20%+ of user messages start with \"no\", \"wrong\", \"wait\" |\n| `keep-going-loop` | User repeatedly says \"keep going\" \u002F \"continue\" |\n| `repeated-instructions` | Same instruction rephrased within 5 turns (Jaccard >60%) |\n| `negative-drift` | Messages get shorter and more corrective over time |\n| `rapid-corrections` | User responds within 10s of agent output |\n| `high-turn-ratio` | User sends 1.5x+ messages per agent response |\n\n### Lexical\n\nAFINN-165 sentiment scoring with custom agent tokens (`undo`, `revert`, `wrong`, `broken`, etc).\n\n## `--rules`\n\nGenerates ready-to-paste rules from your session history:\n\n```\n## Rules (auto-generated by claude-doctor)\n\nBased on analysis of 838 sessions. Paste into your CLAUDE.md or AGENTS.md.\n\n- Read the full file before editing. Plan all changes, then make ONE complete edit.\n- After 2 consecutive tool failures, stop and change your approach entirely.\n- When the user corrects you, stop and re-read their message.\n- Complete the FULL task before stopping.\n- Every few turns, re-read the original request to make sure you haven't drifted.\n```\n\n## `--save`\n\nWrites a model to `.claude-doctor\u002F`:\n\n- `model.json` signal baselines and project profiles\n- `guidance.md` agent-readable rules for hooks or CLAUDE.md inclusion\n\n## Development\n\n```bash\npnpm install\npnpm build\npnpm test\n```\n\n## License\n\nMIT\n","该项目是一个用于诊断Claude代码会话的工具，能够分析用户在`~\u002F.claude\u002F`目录下的会话记录，识别出潜在的行为反模式，并根据历史数据生成CLAUDE.md或AGENTS.md文件中的规则建议。采用TypeScript编写，支持多种命令行参数来满足不同场景的需求，如分析特定会话、过滤项目、生成规则等。通过检测结构、行为和词汇层面的信号，帮助开发者发现诸如频繁编辑同一文件、连续错误循环等问题。适合于需要提高与AI助手协作效率的开发者使用，特别是那些希望优化其与Claude AI交互方式的个人或团队。","2026-06-11 02:40:11","CREATED_QUERY"]