claude-agent-radar 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,27 @@
1
+ # Claude Code 個人/本機設定 (不應共享)
2
+ .claude/settings.local.json
3
+
4
+ # Python
5
+ __pycache__/
6
+ *.pyc
7
+ *.pyo
8
+ .venv/
9
+ venv/
10
+
11
+ # Build artifacts (hatchling / pip / uv)
12
+ build/
13
+ dist/
14
+ *.egg-info/
15
+
16
+ # Local-only credentials for one-off publishes (never committed)
17
+ _token_*.txt
18
+
19
+ # 掃描輸出 (本機產物,保留 sample-scan.json + report.html 作示範)
20
+ scan.json
21
+ session.json
22
+ usage.json
23
+ merged.json
24
+ report-merged.html
25
+ report-session.html
26
+ test-*.json
27
+ test-*.html
@@ -0,0 +1,65 @@
1
+ # CLAUDE.md
2
+
3
+ Behavioral guidelines to reduce common LLM coding mistakes. Merge with project-specific instructions as needed.
4
+
5
+ **Tradeoff:** These guidelines bias toward caution over speed. For trivial tasks, use judgment.
6
+
7
+ ## 1. Think Before Coding
8
+
9
+ **Don't assume. Don't hide confusion. Surface tradeoffs.**
10
+
11
+ Before implementing:
12
+ - State your assumptions explicitly. If uncertain, ask.
13
+ - If multiple interpretations exist, present them - don't pick silently.
14
+ - If a simpler approach exists, say so. Push back when warranted.
15
+ - If something is unclear, stop. Name what's confusing. Ask.
16
+
17
+ ## 2. Simplicity First
18
+
19
+ **Minimum code that solves the problem. Nothing speculative.**
20
+
21
+ - No features beyond what was asked.
22
+ - No abstractions for single-use code.
23
+ - No "flexibility" or "configurability" that wasn't requested.
24
+ - No error handling for impossible scenarios.
25
+ - If you write 200 lines and it could be 50, rewrite it.
26
+
27
+ Ask yourself: "Would a senior engineer say this is overcomplicated?" If yes, simplify.
28
+
29
+ ## 3. Surgical Changes
30
+
31
+ **Touch only what you must. Clean up only your own mess.**
32
+
33
+ When editing existing code:
34
+ - Don't "improve" adjacent code, comments, or formatting.
35
+ - Don't refactor things that aren't broken.
36
+ - Match existing style, even if you'd do it differently.
37
+ - If you notice unrelated dead code, mention it - don't delete it.
38
+
39
+ When your changes create orphans:
40
+ - Remove imports/variables/functions that YOUR changes made unused.
41
+ - Don't remove pre-existing dead code unless asked.
42
+
43
+ The test: Every changed line should trace directly to the user's request.
44
+
45
+ ## 4. Goal-Driven Execution
46
+
47
+ **Define success criteria. Loop until verified.**
48
+
49
+ Transform tasks into verifiable goals:
50
+ - "Add validation" → "Write tests for invalid inputs, then make them pass"
51
+ - "Fix the bug" → "Write a test that reproduces it, then make it pass"
52
+ - "Refactor X" → "Ensure tests pass before and after"
53
+
54
+ For multi-step tasks, state a brief plan:
55
+ ```
56
+ 1. [Step] → verify: [check]
57
+ 2. [Step] → verify: [check]
58
+ 3. [Step] → verify: [check]
59
+ ```
60
+
61
+ Strong success criteria let you loop independently. Weak criteria ("make it work") require constant clarification.
62
+
63
+ ---
64
+
65
+ **These guidelines are working if:** fewer unnecessary changes in diffs, fewer rewrites due to overcomplication, and clarifying questions come before implementation rather than after mistakes.
@@ -0,0 +1,200 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for describing the origin of the Work and
141
+ reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may accept support,
167
+ warranty, indemnity, or other liability obligations and/or rights
168
+ consistent with this License. However, in accepting such obligations,
169
+ You may, on Your own behalf and on Your sole responsibility, not on
170
+ behalf of any other Contributor, and only if You agree to indemnify,
171
+ defend, and hold each Contributor harmless for any liability
172
+ incurred by, or claims asserted against, such Contributor by reason
173
+ of your accepting any such warranty or additional liability.
174
+
175
+ END OF TERMS AND CONDITIONS
176
+
177
+ APPENDIX: How to apply the Apache License to your work.
178
+
179
+ To apply the Apache License to your work, attach the following
180
+ boilerplate notice, with the fields enclosed by brackets "[]"
181
+ replaced with your own identifying information. (Don't include
182
+ the brackets!) The text should be enclosed in the appropriate
183
+ comment syntax for the file format. We also recommend that a
184
+ file or class name and description of purpose be included on the
185
+ same "printed page" as the copyright notice for easier
186
+ identification within third-party archives.
187
+
188
+ Copyright 2026 Miller Lai
189
+
190
+ Licensed under the Apache License, Version 2.0 (the "License");
191
+ you may not use this file except in compliance with the License.
192
+ You may obtain a copy of the License at
193
+
194
+ http://www.apache.org/licenses/LICENSE-2.0
195
+
196
+ Unless required by applicable law or agreed to in writing, software
197
+ distributed under the License is distributed on an "AS IS" BASIS,
198
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
199
+ See the License for the specific language governing permissions and
200
+ limitations under the License.
@@ -0,0 +1,291 @@
1
+ Metadata-Version: 2.4
2
+ Name: claude-agent-radar
3
+ Version: 0.1.0
4
+ Summary: AI Agent capability boundary diagnostic — scan Claude Code filesystem fingerprints into six-dimension maturity scores.
5
+ Project-URL: Homepage, https://github.com/millerlai/agent-radar
6
+ Project-URL: Repository, https://github.com/millerlai/agent-radar
7
+ Project-URL: Issues, https://github.com/millerlai/agent-radar/issues
8
+ Author-email: Miller Lai <miller.lai@gmail.com>
9
+ License-Expression: Apache-2.0
10
+ License-File: LICENSE
11
+ Keywords: agent,claude-code,diagnostic,maturity,radar,skill
12
+ Classifier: Development Status :: 4 - Beta
13
+ Classifier: Environment :: Console
14
+ Classifier: Intended Audience :: Developers
15
+ Classifier: Operating System :: OS Independent
16
+ Classifier: Programming Language :: Python :: 3
17
+ Classifier: Programming Language :: Python :: 3 :: Only
18
+ Classifier: Programming Language :: Python :: 3.8
19
+ Classifier: Programming Language :: Python :: 3.9
20
+ Classifier: Programming Language :: Python :: 3.10
21
+ Classifier: Programming Language :: Python :: 3.11
22
+ Classifier: Programming Language :: Python :: 3.12
23
+ Classifier: Programming Language :: Python :: 3.13
24
+ Classifier: Topic :: Software Development :: Quality Assurance
25
+ Requires-Python: >=3.8
26
+ Description-Content-Type: text/markdown
27
+
28
+ # agent-radar · AI Agent Capability Boundary Diagnostic
29
+
30
+ Detects the *capability boundary* of how an individual or a team uses the Claude Code
31
+ ecosystem. It scans filesystem fingerprints and quantifies a person's mastery of
32
+ CLAUDE.md, skills, MCP, hooks, subagents, and so on into six dimensions of maturity
33
+ score (0–100), then outputs an HTML radar-chart report.
34
+
35
+ **Two-layer measurement:**
36
+
37
+ - `agent-radar scan` measures *configuration completeness* (static fingerprints, six config dimensions)
38
+ - `agent-radar session` reads local `~/.claude/projects/*.jsonl` to measure *actual usage*
39
+ (which tools, Skills, MCP servers actually fire, plus user correction rate)
40
+
41
+ The gap between the two is the most concrete improvement checklist. The repo itself
42
+ is also a Claude Code skill (see `SKILL.md`) — drop it into `~/.claude/skills/agent-radar/`
43
+ and it works out of the box.
44
+
45
+ ## Core Idea
46
+
47
+ How well someone uses Claude Code gets imprinted into their filesystem and session
48
+ logs. This tool reads those fingerprints rather than monitoring conversation content.
49
+
50
+ - **Configuration completeness** (static) reflects how much you've *written down*: CLAUDE.md, skills, MCP.
51
+ - **Actual usage** (dynamic) reflects whether those configs *actually fire* during sessions.
52
+
53
+ Plenty of people write a thorough CLAUDE.md and install five MCP servers, but nothing
54
+ in those configs gets exercised during real sessions. That gap is exactly what
55
+ agent-radar visualizes — two overlaid radar polygons make it obvious.
56
+
57
+ ## Six Config Dimensions (agent-radar scan)
58
+
59
+ | Dimension | What it detects |
60
+ |---|---|
61
+ | CLAUDE.md maturity | Presence, user/project layering, structured sections, imperative tone, concision, `@import` modularization, **size lint** |
62
+ | Skills usage | Whether skills exist, SKILL.md `description` trigger quality, progressive disclosure, **frontmatter & token-hygiene lint** |
63
+ | MCP integration | Number of MCP servers and breadth of types (data / saas / cloud / search / files) |
64
+ | Automation | hooks, subagents, custom slash commands, plugins |
65
+ | Context hygiene | user/project settings separation, shared vs. personal config distinction (gitignore), modular references |
66
+ | Iteration & maintenance | Whether configs have been repeatedly tuned over time (via git history) |
67
+
68
+ **Lint signals** are borrowed from [`felixgeelhaar/cclint`](https://github.com/felixgeelhaar/cclint)
69
+ and the agentskills.io Skill Linter (required frontmatter fields, line-count limits,
70
+ ASCII-art / decorative-content detection, oversized-CLAUDE.md warnings). They are
71
+ reimplemented in pure Python — no external dependencies.
72
+
73
+ The total score maps onto five levels: L0 (unaware) → L4 (mastery).
74
+
75
+ ## Six Usage Dimensions (agent-radar session)
76
+
77
+ | Dimension | What it measures |
78
+ |---|---|
79
+ | tool_diversity | How many distinct tools have been called in the session |
80
+ | skill_triggered | How many times the `Skill` tool actually fired (signal that skill descriptions trigger) |
81
+ | mcp_triggered | How many `mcp__*` tool calls happened (signal that MCP is really used) |
82
+ | low_correction | Rate of corrective user messages (inverted — lower is better) |
83
+ | context_efficiency | Rate of repeated reads of the same file in one session (inverted) |
84
+ | session_volume | Session count and message volume (exposure baseline) |
85
+
86
+ ## Install
87
+
88
+ **Prerequisites**: Python 3.8+ (standard library only — zero external deps).
89
+
90
+ ### Option A · Install from PyPI / source (recommended)
91
+
92
+ Works with `pip`, `uv`, and `poetry`. After install, verify the command
93
+ is on your `PATH`:
94
+
95
+ ```bash
96
+ agent-radar --help
97
+ ```
98
+
99
+ If the verify step prints help, you're done. If it fails with
100
+ `command not found`, see **"`agent-radar` not on PATH?"** below — the
101
+ module form `python -m agent_radar` always works as a drop-in
102
+ replacement.
103
+
104
+ ```bash
105
+ # pip (system / venv)
106
+ pip install agent-radar
107
+
108
+ # pip --user (no admin needed; see PATH note below on Windows)
109
+ pip install --user agent-radar
110
+
111
+ # uv
112
+ uv pip install agent-radar
113
+ # or, as a uv-managed tool (handles PATH for you)
114
+ uv tool install agent-radar
115
+
116
+ # pipx (isolated env, handles PATH for you — recommended on Windows)
117
+ pipx install agent-radar
118
+
119
+ # poetry
120
+ poetry add agent-radar
121
+
122
+ # Local / editable install while hacking on the source
123
+ git clone <repo-url> agent-radar
124
+ cd agent-radar
125
+ pip install -e .
126
+ agent-radar --help
127
+ ```
128
+
129
+ #### `agent-radar` not on PATH?
130
+
131
+ Two common causes:
132
+
133
+ 1. **`pip install --user` on Windows** drops `agent-radar.exe` into
134
+ `%APPDATA%\Python\Python3XX\Scripts\`, which is **not** on `PATH` by
135
+ default. Either add that folder to `PATH`, or reinstall via
136
+ `pipx install agent-radar` / `uv tool install agent-radar` — both
137
+ wire up the entry point automatically.
138
+ 2. **Using a venv that isn't activated** — activate it, or call the
139
+ binary by its full path.
140
+
141
+ In all cases, this module form is a drop-in replacement that needs no
142
+ PATH setup:
143
+
144
+ ```bash
145
+ python -m agent_radar --help
146
+ python -m agent_radar scan ... # same args as `agent-radar scan ...`
147
+ ```
148
+
149
+ ### Option B · Install as a Claude Code skill (recommended for daily use)
150
+
151
+ The repo itself is a Claude Code skill (the root contains `SKILL.md`). Copy
152
+ it into your user-space skills directory:
153
+
154
+ ```bash
155
+ # macOS / Linux / Cygwin
156
+ cp -r /path/to/agent-radar ~/.claude/skills/agent-radar
157
+
158
+ # Windows PowerShell
159
+ Copy-Item -Recurse C:\path\to\agent-radar $env:USERPROFILE\.claude\skills\agent-radar
160
+ ```
161
+
162
+ After that, in any Claude Code session, just say something like the
163
+ following — Claude will load the skill and walk you through the scan:
164
+
165
+ - "audit my Claude Code maturity"
166
+ - "scan this repo's Claude Code setup"
167
+ - "find the blind spots in my agent config"
168
+ - "benchmark our team's Claude Code adoption"
169
+
170
+ The skill invokes the same `agent-radar` CLI, so the package must be
171
+ `pip install`-ed first (or you must launch it via `python -m agent_radar`
172
+ from inside the skill directory).
173
+
174
+ ## Run
175
+
176
+ ### 30-second quick start
177
+
178
+ Scan the current repo + your user-space, generate the full HTML report
179
+ including the actual-usage radar. Run from the repo you want to scan:
180
+
181
+ ```bash
182
+ agent-radar scan --include-home . -o scan.json
183
+ agent-radar session -o session.json
184
+ agent-radar report scan.json --session session.json -o report.html
185
+
186
+ # Open the report
187
+ open report.html # macOS
188
+ xdg-open report.html # Linux
189
+ start report.html # Windows (PowerShell / cmd)
190
+ ```
191
+
192
+ If `agent-radar` is not found, swap every `agent-radar` for
193
+ `python -m agent_radar` (same arguments). See
194
+ [**`agent-radar` not on PATH?**](#agent-radar-not-on-path) above.
195
+
196
+ ### Subcommands
197
+
198
+ | Subcommand | Purpose |
199
+ |---|---|
200
+ | `agent-radar scan` | Scan filesystem fingerprints (six config dimensions) |
201
+ | `agent-radar session` | Scan local `~/.claude/projects/*.jsonl` for actual-usage metrics |
202
+ | `agent-radar report` | Build single-file HTML radar report |
203
+ | `agent-radar usage` | Score OTel events into `usage.json` |
204
+ | `agent-radar merge` | Merge `scan.json` + `usage.json` into `merged.json` |
205
+
206
+ Each subcommand has its own `--help`. Long form: `python -m agent_radar <sub> ...`.
207
+
208
+ ### Three scan scenarios
209
+
210
+ **Scenario 1 · Single repo (simplest)**
211
+
212
+ ```bash
213
+ agent-radar scan /path/to/repo -o scan.json
214
+ agent-radar report scan.json -o report.html
215
+ ```
216
+
217
+ **Scenario 2 · Personal full-body scan (includes user-space)**
218
+
219
+ Pulls `~/.claude/` into the scan so you can see user-level vs project-level
220
+ config separation:
221
+
222
+ ```bash
223
+ agent-radar scan --include-home /path/to/repo -o scan.json
224
+ agent-radar report scan.json -o report.html
225
+ ```
226
+
227
+ **Scenario 3 · Team benchmark (multi-repo)**
228
+
229
+ Scan many repos at once. The report auto-generates a ranking table:
230
+
231
+ ```bash
232
+ agent-radar scan /repos/a /repos/b /repos/c -o scan.json
233
+ agent-radar report scan.json -o report.html
234
+ ```
235
+
236
+ ### Add actual-usage measurement (full two-layer analysis)
237
+
238
+ `agent-radar session` reads local `~/.claude/projects/*.jsonl` and emits
239
+ usage metrics — actual tool invocations, Skill firings, MCP calls, and
240
+ user-correction rate. Pair it with `agent-radar report --session` to get a
241
+ second radar in the HTML:
242
+
243
+ ```bash
244
+ # 1. Scan all projects (defaults to ~/.claude/projects/)
245
+ agent-radar session -o session.json
246
+
247
+ # Or restrict to specific repos
248
+ agent-radar session /path/to/repo -o session.json
249
+
250
+ # 2. Cygwin / cross-OS: point at the actual projects dir
251
+ agent-radar session --projects-dir /c/Users/<you>/.claude/projects -o session.json
252
+
253
+ # 3. Build the two-layer radar report
254
+ agent-radar report scan.json --session session.json -o report.html
255
+ ```
256
+
257
+ ### Output files
258
+
259
+ | File | Produced by | Contents |
260
+ |---|---|---|
261
+ | `scan.json` | `agent-radar scan` | Config completeness: six dimension scores + per-signal detail |
262
+ | `session.json` | `agent-radar session` | Actual usage: per-project tool calls, Skill / MCP triggers, correction rate |
263
+ | `report.html` | `agent-radar report` | Single-file, offline-viewable HTML report with radars + ranking + accordions |
264
+
265
+ ### Full CLI flags
266
+
267
+ ```bash
268
+ agent-radar --help # list subcommands + version
269
+ agent-radar scan --help # paths, --include-home, -o
270
+ agent-radar session --help # paths, --projects-dir, -o
271
+ agent-radar report --help # input, --session, --merged, --lang, -o
272
+ agent-radar usage --help # --otel-log, --scan, --target, --account, ...
273
+ agent-radar merge --help # scan.json, usage.json, -o
274
+ ```
275
+
276
+ ## Limitations
277
+
278
+ - Only effective for targets you have filesystem access to (your own / your team's repos).
279
+ - For strangers with only code or a conversation, reliable detection is impossible,
280
+ and it edges into the gray area of surveilling others — not recommended.
281
+ - `agent-radar session` only reads local JSONL; cross-machine measurement needs OpenTelemetry (`agent-radar usage`).
282
+ - Correction rate is matched on literal patterns (no/don't/stop/不對/還原…); semantic
283
+ corrections (a long explanation of why Claude was wrong) are not detected.
284
+ - The scoring weights are tunable heuristics — calibrate them against your team's
285
+ reality before doing cross-person comparisons.
286
+
287
+ ## License
288
+
289
+ Apache License 2.0 — see [LICENSE](LICENSE).
290
+
291
+ Copyright 2026 Miller Lai.