@praneeth_54/agentdoctor 2.1.0 → 3.0.1

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.
Files changed (167) hide show
  1. package/CHANGELOG.md +86 -3
  2. package/README.md +490 -290
  3. package/dist/agent/chat/deterministic.d.ts +6 -0
  4. package/dist/agent/chat/deterministic.js +180 -0
  5. package/dist/agent/chat/service.js +8 -14
  6. package/dist/agent/context/retrieve.d.ts +2 -1
  7. package/dist/agent/context/retrieve.js +14 -1
  8. package/dist/agent/index.d.ts +2 -0
  9. package/dist/agent/index.js +1 -0
  10. package/dist/agent/loop.d.ts +2 -0
  11. package/dist/agent/loop.js +31 -0
  12. package/dist/agent/roles.d.ts +12 -0
  13. package/dist/agent/roles.js +138 -0
  14. package/dist/agent/runtime.d.ts +21 -5
  15. package/dist/agent/runtime.js +141 -28
  16. package/dist/agent/tools/execute.d.ts +2 -0
  17. package/dist/agent/tools/execute.js +49 -43
  18. package/dist/agent/tools/write.d.ts +1 -1
  19. package/dist/agent/tools/write.js +18 -4
  20. package/dist/ai/config.js +1 -0
  21. package/dist/ai/providers/adversarial-local.d.ts +7 -0
  22. package/dist/ai/providers/adversarial-local.js +146 -0
  23. package/dist/ai/redact.d.ts +1 -0
  24. package/dist/ai/redact.js +47 -7
  25. package/dist/ai/types.d.ts +1 -1
  26. package/dist/cli/commands/agent.d.ts +2 -0
  27. package/dist/cli/commands/agent.js +32 -11
  28. package/dist/cli/commands/architecture.js +7 -2
  29. package/dist/cli/commands/brain.js +7 -2
  30. package/dist/cli/commands/chat.js +15 -7
  31. package/dist/cli/commands/complete.js +13 -3
  32. package/dist/cli/commands/fix.js +6 -0
  33. package/dist/cli/commands/learn.js +7 -2
  34. package/dist/cli/commands/mcp.js +7 -3
  35. package/dist/cli/commands/platform.js +7 -2
  36. package/dist/cli/commands/policy-graph-run.js +7 -0
  37. package/dist/cli/commands/product.d.ts +19 -0
  38. package/dist/cli/commands/product.js +157 -0
  39. package/dist/cli/commands/scan.js +6 -0
  40. package/dist/cli/commands/start.d.ts +15 -0
  41. package/dist/cli/commands/start.js +86 -0
  42. package/dist/cli/commands/v2.js +61 -11
  43. package/dist/cli/commands/verify.js +6 -0
  44. package/dist/cli/program.js +141 -0
  45. package/dist/cli/safe-root.d.ts +17 -0
  46. package/dist/cli/safe-root.js +32 -0
  47. package/dist/constants.d.ts +1 -1
  48. package/dist/constants.js +1 -1
  49. package/dist/core/brain-cli/service.js +5 -2
  50. package/dist/core/monorepo/detect.js +10 -0
  51. package/dist/core/secrets/scan.js +9 -0
  52. package/dist/core/understanding/brain/storage/store.d.ts +4 -0
  53. package/dist/core/understanding/brain/storage/store.js +22 -2
  54. package/dist/dashboard/page.d.ts +2 -0
  55. package/dist/dashboard/page.js +53 -0
  56. package/dist/dashboard/server.js +117 -140
  57. package/dist/dashboard/ui/client.d.ts +2 -0
  58. package/dist/dashboard/ui/client.js +2 -0
  59. package/dist/dashboard/ui/styles.d.ts +2 -0
  60. package/dist/dashboard/ui/styles.js +138 -0
  61. package/dist/discovery/files.js +13 -0
  62. package/dist/index.d.ts +4 -0
  63. package/dist/index.js +2 -0
  64. package/dist/intelligence/graph/build.js +46 -38
  65. package/dist/intelligence/graph/incremental.d.ts +2 -0
  66. package/dist/intelligence/graph/incremental.js +9 -0
  67. package/dist/intelligence/resolve/imports.js +1 -1
  68. package/dist/languages/dart.d.ts +10 -0
  69. package/dist/languages/dart.js +99 -0
  70. package/dist/languages/go.d.ts +13 -7
  71. package/dist/languages/go.js +84 -24
  72. package/dist/languages/index.d.ts +5 -1
  73. package/dist/languages/index.js +13 -36
  74. package/dist/languages/java.d.ts +10 -0
  75. package/dist/languages/java.js +80 -0
  76. package/dist/languages/kotlin.d.ts +10 -0
  77. package/dist/languages/kotlin.js +85 -0
  78. package/dist/languages/rust.d.ts +10 -0
  79. package/dist/languages/rust.js +93 -0
  80. package/dist/languages/types.d.ts +4 -3
  81. package/dist/mcp/agent/registry.d.ts +1 -1
  82. package/dist/mcp/agent/registry.js +109 -23
  83. package/dist/mcp/intelligence/handlers.d.ts +3 -0
  84. package/dist/mcp/intelligence/handlers.js +28 -0
  85. package/dist/mcp/intelligence/path-safety.d.ts +6 -1
  86. package/dist/mcp/intelligence/path-safety.js +55 -2
  87. package/dist/mcp/intelligence/registry.d.ts +1 -1
  88. package/dist/mcp/intelligence/registry.js +30 -1
  89. package/dist/platform/graph/build.js +9 -0
  90. package/dist/product/api/doctor.d.ts +14 -0
  91. package/dist/product/api/doctor.js +185 -0
  92. package/dist/product/api/openapi.d.ts +7 -0
  93. package/dist/product/api/openapi.js +122 -0
  94. package/dist/product/approval/model.d.ts +30 -0
  95. package/dist/product/approval/model.js +64 -0
  96. package/dist/product/approval/session.d.ts +49 -0
  97. package/dist/product/approval/session.js +134 -0
  98. package/dist/product/database/doctor.d.ts +30 -0
  99. package/dist/product/database/doctor.js +184 -0
  100. package/dist/product/decisions/ledger.d.ts +36 -0
  101. package/dist/product/decisions/ledger.js +141 -0
  102. package/dist/product/deps/analyze.d.ts +46 -0
  103. package/dist/product/deps/analyze.js +137 -0
  104. package/dist/product/deps/lockfiles.d.ts +25 -0
  105. package/dist/product/deps/lockfiles.js +200 -0
  106. package/dist/product/discovery/roots.d.ts +52 -0
  107. package/dist/product/discovery/roots.js +231 -0
  108. package/dist/product/dna/build.d.ts +50 -0
  109. package/dist/product/dna/build.js +255 -0
  110. package/dist/product/eval/lab.d.ts +17 -0
  111. package/dist/product/eval/lab.js +218 -0
  112. package/dist/product/events/doctor.d.ts +21 -0
  113. package/dist/product/events/doctor.js +147 -0
  114. package/dist/product/evidence-scan.d.ts +12 -0
  115. package/dist/product/evidence-scan.js +46 -0
  116. package/dist/product/evolution/timeline.d.ts +29 -0
  117. package/dist/product/evolution/timeline.js +123 -0
  118. package/dist/product/features/intelligence.d.ts +23 -0
  119. package/dist/product/features/intelligence.js +158 -0
  120. package/dist/product/forensic/mode.d.ts +25 -0
  121. package/dist/product/forensic/mode.js +70 -0
  122. package/dist/product/graph/enrich-languages.d.ts +20 -0
  123. package/dist/product/graph/enrich-languages.js +168 -0
  124. package/dist/product/health/code-health.d.ts +20 -0
  125. package/dist/product/health/code-health.js +149 -0
  126. package/dist/product/index.d.ts +72 -0
  127. package/dist/product/index.js +36 -0
  128. package/dist/product/ledger/change-ledger.d.ts +23 -0
  129. package/dist/product/ledger/change-ledger.js +64 -0
  130. package/dist/product/map/software-map.d.ts +17 -0
  131. package/dist/product/map/software-map.js +96 -0
  132. package/dist/product/memory/institutional.d.ts +16 -0
  133. package/dist/product/memory/institutional.js +92 -0
  134. package/dist/product/ops/incident.d.ts +20 -0
  135. package/dist/product/ops/incident.js +61 -0
  136. package/dist/product/ops/infra.d.ts +15 -0
  137. package/dist/product/ops/infra.js +112 -0
  138. package/dist/product/org/model.d.ts +34 -0
  139. package/dist/product/org/model.js +195 -0
  140. package/dist/product/privacy/doctor.d.ts +13 -0
  141. package/dist/product/privacy/doctor.js +90 -0
  142. package/dist/product/requirements/trace.d.ts +21 -0
  143. package/dist/product/requirements/trace.js +166 -0
  144. package/dist/product/search/index.d.ts +29 -0
  145. package/dist/product/search/index.js +116 -0
  146. package/dist/product/search/software-search.d.ts +19 -0
  147. package/dist/product/search/software-search.js +105 -0
  148. package/dist/product/security/doctor.d.ts +23 -0
  149. package/dist/product/security/doctor.js +124 -0
  150. package/dist/product/self/diagnose.d.ts +15 -0
  151. package/dist/product/self/diagnose.js +82 -0
  152. package/dist/product/techdebt/roadmap.d.ts +20 -0
  153. package/dist/product/techdebt/roadmap.js +118 -0
  154. package/dist/product/testbrain/analyze.d.ts +29 -0
  155. package/dist/product/testbrain/analyze.js +129 -0
  156. package/dist/product/truth.d.ts +12 -0
  157. package/dist/product/truth.js +30 -0
  158. package/dist/product/twin/digital-twin.d.ts +23 -0
  159. package/dist/product/twin/digital-twin.js +52 -0
  160. package/dist/product/twin/store.d.ts +21 -0
  161. package/dist/product/twin/store.js +78 -0
  162. package/dist/product/whatif/engine.d.ts +28 -0
  163. package/dist/product/whatif/engine.js +91 -0
  164. package/dist/project/ownership.d.ts +65 -0
  165. package/dist/project/ownership.js +169 -0
  166. package/dist/utils/fs.js +10 -2
  167. package/package.json +1 -1
package/README.md CHANGED
@@ -1,41 +1,46 @@
1
1
  # AgentDoctor
2
2
 
3
- ## Engineering assurance for AI coding agents.
3
+ ### The intelligence and assurance layer for software projects.
4
4
 
5
- Understand your codebase, assess the impact of changes, govern engineering knowledge, enforce safety policies, and attach inspectable evidence to AI-driven changes.
5
+ **Understand your codebase. Build safely. Verify the result.**
6
+
7
+ Ask questions about a real repository. Plan a change. Require approval. Edit under path-safe controls. Map tests and risk. Attach evidence. Prove integrity — without pretending the change is “correct.”
6
8
 
7
9
  [![npm](https://img.shields.io/npm/v/@praneeth_54/agentdoctor?label=npm)](https://www.npmjs.com/package/@praneeth_54/agentdoctor)
8
10
  [![CI](https://img.shields.io/github/actions/workflow/status/pranee54/AgentDoctor/ci.yml?branch=main&label=CI)](https://github.com/pranee54/AgentDoctor/actions/workflows/ci.yml)
9
11
  [![Node](https://img.shields.io/node/v/@praneeth_54/agentdoctor)](https://nodejs.org)
10
- [![License](https://img.shields.io/github/license/pranee54/AgentDoctor)](LICENSE)
12
+ [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
11
13
 
12
- **Published:** [`@praneeth_54/agentdoctor@2.1.0`](https://www.npmjs.com/package/@praneeth_54/agentdoctor)
13
- **Release notes:** [docs/RELEASE_2_1_0.md](docs/RELEASE_2_1_0.md) · Prior assurance cut: [docs/2.0.1/README.md](docs/2.0.1/README.md)
14
+ **Published package:** [`@praneeth_54/agentdoctor`](https://www.npmjs.com/package/@praneeth_54/agentdoctor)
15
+ **Current product:** **3.0** — project intelligence & assurance core (see [Verification](#verification))
14
16
 
15
- [Install](#install) · [Quickstart](#quickstart) · [Change assurance](#change-assurance) · [Project AI (2.1)](#project-ai-agent-21) · [Documentation](docs/2.0.1/README.md) · [MCP](#mcp) · [GitHub Action](#github-action) · [Architecture](#architecture)
17
+ [Install](#install) · [5-minute quickstart](#five-minute-quickstart) · [What it can do](#what-can-it-do) · [Students](#for-students) · [MCP](#mcp) · [Security](#security-model) · [Limitations](#limitations) · [Docs](#documentation)
16
18
 
17
19
  ---
18
20
 
19
- ## What AgentDoctor is
21
+ ## What is AgentDoctor?
20
22
 
21
- AgentDoctor sits between developers / AI coding agents and the repository’s engineering reality.
23
+ AgentDoctor is a **project-aware intelligence and assurance platform**. It helps people understand, learn, plan, safely change, test, secure, verify, and remember software projects — whether the code was written by hand, with AI, or by a coding agent.
22
24
 
23
- AI agents can write code quickly. The harder engineering problem is knowing whether a change is **correct, safe, compatible, explainable, and consistent** with the rest of the repository.
25
+ Most tools answer one slice of the problem:
24
26
 
25
- AgentDoctor collects repository signals — source structure, graphs, Git history, policies, knowledge, and verification evidence — so humans and agents can reason about changes with fewer unsupported assumptions.
27
+ | Tool type | Typical job |
28
+ | ----------------- | --------------------- |
29
+ | Linters | Style / static issues |
30
+ | Test runners | Execute tests |
31
+ | Code search | Find text / symbols |
32
+ | Security scanners | Find vulnerabilities |
33
+ | AI coding agents | Propose / apply edits |
26
34
 
27
- **Who it is for**
35
+ AgentDoctor connects those concerns around **the project itself**. It builds local understanding of structure, relationships, dependencies, Git, tests, security signals, requirements, and evidence — then uses that understanding across:
28
36
 
29
- | Audience | How AgentDoctor helps |
30
- | ---------------------- | ----------------------------------------------------------------------------- |
31
- | Manual developers | Scan / fix / verify, change impact, evidence, architecture and policy checks |
32
- | Students | `learn` — explain project, viva, docs; **BUILD_WITH_ME** after approval |
33
- | AI-assisted developers | Optional Project Chat (`ask` / `chat`) with evidence and truth labels |
34
- | AI coding agents | MCP + controlled tools; AgentDoctor owns context, execution, and verification |
37
+ ```text
38
+ UNDERSTAND → ASK → PLAN → APPROVE → CHANGE → TEST → SECURE → VERIFY → PROVE
39
+ ```
35
40
 
36
- It is **not** a generic chatbot, IDE interceptor, or claim of full autonomy. Optional Project AI (2.1) is **opt-in** and still subject to approvals, path/runner controls, and verification. It does **not** guarantee correctness. It produces **evidence and controls** you can inspect.
41
+ It is **not** “another chatbot,” a Cursor clone, a generic coding agent, or a claim of full autonomy.
37
42
 
38
- **Architecture (when AI is enabled):**
43
+ **Invariant**
39
44
 
40
45
  ```text
41
46
  THE MODEL REASONS.
@@ -44,192 +49,230 @@ AGENTDOCTOR CONTROLS TOOLS.
44
49
  AGENTDOCTOR VERIFIES RESULTS.
45
50
  ```
46
51
 
47
- **Short description:** Engineering assurance for AI coding agents — repository intelligence, change evidence, safety controls, MCP tools, and an optional Project AI Agent.
52
+ The model is **not** the source of truth. Repository evidence is.
48
53
 
49
54
  ---
50
55
 
51
- ## Why AgentDoctor?
56
+ ## Why it exists
52
57
 
53
- Modern AI coding agents can:
58
+ AI tools can write code quickly. Engineering still needs answers to:
54
59
 
55
- - read individual files
56
- - generate and edit code
57
- - run tests when asked
60
+ - What is this project?
61
+ - What depends on this module?
62
+ - What breaks if I change it?
63
+ - Which tests matter?
64
+ - Is this change within policy / workspace bounds?
65
+ - Did the requested change actually happen?
66
+ - What evidence supports the result?
67
+ - What remains UNKNOWN?
58
68
 
59
- Repository-level context is usually fragmented across:
69
+ AgentDoctor exists for that loop — locally, inspectably, with explicit truth labels.
60
70
 
61
- | Signal | Typical location |
62
- | ------------------ | ------------------------------ |
63
- | Source structure | AST / imports / modules |
64
- | Dependencies | manifests / lockfiles |
65
- | History | Git |
66
- | Architecture | docs / conventions / inference |
67
- | Tests | test trees / naming heuristics |
68
- | Policy | CI rules / allowlists |
69
- | Decisions | ADRs / RFCs / tribal knowledge |
70
- | Secrets / exposure | config files / ignore rules |
71
+ ---
71
72
 
72
- AgentDoctor brings those signals into one local toolchain around an AI-driven engineering change:
73
+ ## How it works
73
74
 
74
75
  ```text
75
- Developer / AI Agent
76
- │
77
- ▼
78
- AgentDoctor
79
- │
80
- ┌───────────────────────────────┐
81
- │ Repository Intelligence │
82
- │ AST / Graph / Git / Impact │
83
- ├───────────────────────────────┤
84
- │ Engineering Knowledge │
85
- │ Brain / Decisions / Provenance│
86
- ├───────────────────────────────┤
87
- │ Safety & Policy │
88
- │ Scan / Fix / Enforce / Secrets│
89
- ├───────────────────────────────┤
90
- │ Verification │
91
- │ Tests / Reports / Evidence │
92
- └───────────────────────────────┘
93
- │
94
- ▼
95
- Safer, explainable engineering decisions
76
+ User / Student / Developer / AI agent
77
+ │
78
+ ▼
79
+ AgentDoctor
80
+ (CLI · MCP · Dashboard)
81
+ │
82
+ ▼
83
+ Project Understanding
84
+ ┌─────────────┬─────────────┬──────────────┐
85
+ │ Project Brain │ Code Graph │ Project DNA │
86
+ │ Architecture │ Deps/Git │ Tests/Sec │
87
+ │ Requirements │ Search │ Evidence │
88
+ └─────────────┴─────────────┴──────────────┘
89
+ │
90
+ ▼
91
+ Reasoning (optional LLM / deterministic)
92
+ │
93
+ ▼
94
+ Controlled tools (path-safe)
95
+ │
96
+ ▼
97
+ Verification · Evidence · Proof
96
98
  ```
97
99
 
98
100
  ---
99
101
 
100
- ## Capability map
101
-
102
- Status labels: **SUPPORTED** · **PARTIAL** · **EXPERIMENTAL** · **NOT YET SUPPORTED**
102
+ ## Who is it for?
103
103
 
104
- Details and evidence: [docs/2.0/overview/capabilities.md](docs/2.0/overview/capabilities.md) · [readiness matrix](docs/2.0/overview/readiness-matrix.md)
104
+ ### Students
105
105
 
106
- ### Repository intelligence
106
+ College / B.Tech / final-year projects, inherited repos, viva prep, documentation.
107
107
 
108
- | Capability | Status |
109
- | ---------------------------------------------------- | ------------ |
110
- | TypeScript / JavaScript AST graph (+ regex fallback) | PARTIAL |
111
- | Import / inferred call relationships | PARTIAL |
112
- | Git hotspot / engineering intelligence | PARTIAL |
113
- | Change / test / refactor impact | PARTIAL |
114
- | C4-style architecture views | EXPERIMENTAL |
108
+ ```bash
109
+ agentdoctor start
110
+ agentdoctor learn .
111
+ agentdoctor learn . --viva
112
+ agentdoctor learn . --docs
113
+ agentdoctor ask "Explain authentication like a beginner." .
114
+ ```
115
115
 
116
- ### Engineering knowledge
116
+ Use **Build With Me** only with explicit approval (`--approve`) before writes.
117
117
 
118
- | Capability | Status |
119
- | ------------------------------------------------------------- | --------- |
120
- | Project Brain store + evidence-backed claims | SUPPORTED |
121
- | Repository Brain init / proposal review (never auto-approved) | PARTIAL |
122
- | Governed knowledge + abstention on retrieve | PARTIAL |
123
- | Provenance envelopes on Brain MCP tools | SUPPORTED |
118
+ ### Developers
124
119
 
125
- ### Agent interfaces
120
+ Inherited codebases, impact analysis, deps, architecture, change assurance.
126
121
 
127
- | Capability | Status |
128
- | --------------------------------------------------------------------------------- | --------- |
129
- | Brain MCP (`brain_*` tools, STDIO) | SUPPORTED |
130
- | Combined MCP (Brain + intelligence tools) | PARTIAL |
131
- | Agent MCP (`project_ask`, path-safe file tools, plan, change verify) — 2.1 | PARTIAL |
132
- | Optional Project Chat / coding agent CLI (`chat`, `ask`, `agent`, `learn`) — 2.1 | PARTIAL |
133
- | Agent adapters (Cursor, Claude Code, Codex, Copilot, Windsurf, Gemini CLI, Aider) | SUPPORTED |
134
- | Local dashboard + `/api/v2/*` + ask-only `/api/chat` — 2.1 | PARTIAL |
135
- | Programmatic API (`scan`, Fix, Brain helpers) | SUPPORTED |
122
+ ```bash
123
+ agentdoctor dna .
124
+ agentdoctor graph .
125
+ agentdoctor map .
126
+ agentdoctor deps .
127
+ agentdoctor search "login" .
128
+ agentdoctor what-if src/auth.js .
129
+ agentdoctor change analyze .
130
+ ```
136
131
 
137
- ### Safety & governance
132
+ ### AI-assisted developers
138
133
 
139
- | Capability | Status |
140
- | -------------------------------------------------------- | --------------------- |
141
- | Scan → Safe Fix → Verify | SUPPORTED |
142
- | Policy gates (`--min-score`, severity, rule, verify-new) | SUPPORTED |
143
- | Evaluate-only policy / controlled enforcement runner | PARTIAL |
144
- | Secret scan (redacted findings) + export redaction | PARTIAL |
145
- | Path-safety for MCP / dashboard | PARTIAL |
146
- | Local-dev team auth (scrypt) | PARTIAL — **not SSO** |
134
+ Works alongside Cursor, Claude Code, Codex, Copilot, Windsurf, Gemini CLI, Aider, and similar workflows as an **assurance / intelligence layer** (scan adapters + MCP) — not as a replacement IDE.
147
135
 
148
- ### Verification
136
+ ```bash
137
+ agentdoctor mcp --root /absolute/path/to/project
138
+ agentdoctor plan "Add password reset" .
139
+ agentdoctor agent --goal "…" --approve --apply --apply-ops '[...]' .
140
+ ```
149
141
 
150
- | Capability | Status |
151
- | ------------------------------------------------------- | -------------------------- |
152
- | Change assurance assessment + evidence bundles | PARTIAL |
153
- | Evidence hash verify (`verified` = integrity only) | SUPPORTED |
154
- | Unit / integration / MCP STDIO tests (`npm run verify`) | SUPPORTED |
155
- | Packed CLI clean-install smoke | SUPPORTED |
156
- | Reproducible AST perf harness | PARTIAL (synthetic sample) |
142
+ ### Security / reviewers
157
143
 
158
- ---
144
+ Secrets (redacted), technical security heuristics, forensic read-only mode, path/approval controls, evidence.
159
145
 
160
- ## How AgentDoctor is different
146
+ ```bash
147
+ agentdoctor secrets .
148
+ agentdoctor security-doctor .
149
+ AGENTDOCTOR_FORENSIC_MODE=1 agentdoctor forensic .
150
+ agentdoctor evidence verify <changeId> .
151
+ ```
161
152
 
162
- Most engineering tools optimize one layer: static analysis, search, docs generation, dashboards, security scanners, or AI chat.
153
+ ### Teams / owners
163
154
 
164
- AgentDoctor is designed around the **lifecycle of an AI-driven change**:
155
+ Local project DNA, twin snapshots, decisions/ADRs, org catalog (local JSON — not enterprise SSO).
165
156
 
166
- ```text
167
- Repository
168
- → Understand
169
- → Impact
170
- → Knowledge
171
- → Policy
172
- → Change
173
- → Verification
174
- → Evidence
157
+ ```bash
158
+ agentdoctor twin .
159
+ agentdoctor decisions .
160
+ agentdoctor org .
161
+ agentdoctor dashboard .
175
162
  ```
176
163
 
177
- That combination is the product direction. It does not mean every layer is equally mature — see the capability map and limitations.
164
+ ---
165
+
166
+ ## What can it do?
167
+
168
+ Status below = **complete at defined local scope** (see [docs/LIMITATIONS.md](docs/LIMITATIONS.md)). **EXTERNAL** means outside systems are required for that upgrade path.
169
+
170
+ ### Understand
171
+
172
+ | Capability | CLI / surface | Notes |
173
+ | -------------------------------- | -------------------- | ------------------------------ |
174
+ | Safe project discovery | `start` | Refuses home/Desktop dumps |
175
+ | Project DNA | `dna`, `start` | Manifest / marker evidence |
176
+ | Code graph + AST | `graph` | Strong TS/JS; host/line others |
177
+ | Architecture / C4 | `architecture`, `c4` | Advisory unless you gate it |
178
+ | Dependencies + lockfiles | `deps` | VERIFIED when lock parsed |
179
+ | Software map / code health | `map`, `health-code` | Layout + indicators |
180
+ | Project Brain | `brain`, MCP | Local, deterministic |
181
+ | Requirements / API / DB / events | `requirements`, … | File evidence; live = EXTERNAL |
182
+
183
+ ### Ask
184
+
185
+ | Capability | CLI / surface | Notes |
186
+ | ------------ | ------------- | ---------------------------------------- |
187
+ | Project Chat | `ask`, `chat` | Deterministic without LLM; LLM optional |
188
+ | Truth labels | responses | VERIFIED / INFERRED / UNKNOWN / EXTERNAL |
189
+ | Search | `search`, MCP | Lexical / TF-IDF; embeddings = EXTERNAL |
190
+
191
+ ### Build
192
+
193
+ | Capability | CLI / surface | Notes |
194
+ | ----------------- | --------------------- | -------------------------------------------- |
195
+ | Plan | `plan` | No writes |
196
+ | Coding agent | `agent`, `role-agent` | Writes need `--approve` |
197
+ | MCP agent tools | `mcp` | Token + planHash; bare `approved:true` fails |
198
+ | Controlled runner | `run`, `policy` | Shell off by default |
199
+
200
+ ### Test
201
+
202
+ | Capability | CLI / surface | Notes |
203
+ | -------------- | ------------- | --------------------------------------- |
204
+ | Test Brain | `test-brain` | Mapping / impact — not mutation testing |
205
+ | Impact | `impact` | Heuristic; coverage optional |
206
+ | Evaluation lab | `eval-lab` | Fixture checks |
207
+
208
+ ### Secure
209
+
210
+ | Capability | CLI / surface | Notes |
211
+ | ------------------ | ------------------ | ---------------------------------------- |
212
+ | Secrets (redacted) | `secrets` | Values never printed |
213
+ | Security Doctor | `security-doctor` | Technical heuristics ≠ commercial SAST |
214
+ | Forensic mode | `forensic` + env | Read-only; blocks writes/exec |
215
+ | Path / workspace | all write surfaces | Traversal / symlink escape blocked |
216
+ | Privacy Doctor | `privacy-doctor` | Technical PII-ish — not legal compliance |
217
+
218
+ ### Verify
219
+
220
+ | Capability | CLI / surface | Notes |
221
+ | ------------------- | ------------------------------------ | ----------------------------------- |
222
+ | Change analyze | `change analyze` | |
223
+ | Evidence / proof | `change verify`, `evidence`, `proof` | Integrity ≠ engineering correctness |
224
+ | Scan → Fix → Verify | `scan`, `fix`, `verify` | Agent-config safety |
225
+ | Self-check | `self-check` | Installation diagnosis |
226
+
227
+ ### Learn
228
+
229
+ | Capability | CLI |
230
+ | ------------------- | -------------------------------------------------- |
231
+ | Learn / viva / docs | `learn`, `--viva`, `--docs` |
232
+ | Build With Me | `learn --mode BUILD_WITH_ME --build "…" --approve` |
233
+
234
+ ### Remember / operate (local)
235
+
236
+ | Capability | CLI / surface | Boundary |
237
+ | --------------------- | ------------------------ | ------------------------------------------------ |
238
+ | Decisions / evolution | `decisions`, `evolution` | Local ledgers / git |
239
+ | Digital Twin | `twin` | Local snapshot — not live runtime twin |
240
+ | What-if | `what-if` | Graph impact — not certainty |
241
+ | Infra markers | `infra` | Compose/K8s/TF **files** — live cluster EXTERNAL |
242
+ | Incident hypotheses | `incident` | Not auto-verified root cause; APM EXTERNAL |
243
+ | Org catalog | `org` | Local JSON — IdP EXTERNAL |
178
244
 
179
245
  ---
180
246
 
181
- ## Architecture
247
+ ## Not just a coding agent
248
+
249
+ A coding agent can modify files. AgentDoctor is built for the full loop:
182
250
 
183
251
  ```text
184
- AgentDoctor
185
- │
186
- ├── Repository Intelligence
187
- │ ├── AST (TS/JS)
188
- │ ├── Graph
189
- │ ├── Git
190
- │ └── Impact
191
- │
192
- ├── Engineering Knowledge
193
- │ ├── Brain
194
- │ ├── Governance
195
- │ └── Provenance
196
- │
197
- ├── Safety
198
- │ ├── Scanner
199
- │ ├── Safe Fix
200
- │ ├── Secrets
201
- │ └── Policies
202
- │
203
- ├── Agent Interface
204
- │ ├── MCP (brain-mcp / mcp)
205
- │ ├── CLI
206
- │ ├── API / dashboard
207
- │ └── Adapters
208
- │
209
- └── Verification
210
- ├── Tests
211
- ├── Reports
212
- └── Release validation
252
+ UNDERSTAND → PLAN → APPROVE → CHANGE → TEST → SECURE → VERIFY → PROVE
213
253
  ```
214
254
 
215
- Code layout: `src/{intelligence,knowledge,core,mcp,platform,enforcement,cli}/`
255
+ **Don't just generate a change. Understand the project and verify the change.**
216
256
 
217
- Canonical docs: [docs/2.0/overview/architecture.md](docs/2.0/overview/architecture.md)
257
+ Proof means **hash integrity over evidence**, with:
258
+
259
+ `ENGINEERING_CORRECTNESS_NOT_CLAIMED`
218
260
 
219
261
  ---
220
262
 
221
- ## Engineering principles
263
+ ## Workflow: “Add password reset”
264
+
265
+ 1. `agentdoctor start` — discover project, DNA, Brain
266
+ 2. `agentdoctor ask "How does authentication work?"` — evidence-backed / deterministic paths
267
+ 3. `agentdoctor search login` / `what-if src/auth.js` — related files & tests
268
+ 4. `agentdoctor plan "Add password reset"` — plan only; **no writes**
269
+ 5. Review risk; approve explicitly
270
+ 6. `agentdoctor agent --goal "Add password reset" --approve --apply --apply-ops '[…]'` — path-safe tools
271
+ 7. `agentdoctor change analyze` / `change verify` — assessment + evidence
272
+ 8. `agentdoctor proof` — integrity check
273
+ 9. Read **Verified / Not verified / UNKNOWN** — never treat integrity as product correctness
222
274
 
223
- 1. Evidence over assumptions
224
- 2. Explicit limitations over inflated claims
225
- 3. Safety before automation
226
- 4. Repository context over isolated files
227
- 5. Human approval for governed decisions
228
- 6. Backwards compatibility where documented
229
- 7. Reproducible verification
230
- 8. Explainable agent actions
231
- 9. Least privilege
232
- 10. Secure defaults
275
+ Student path: `learn` → ask → viva → docs → Build With Me (with `--approve`).
233
276
 
234
277
  ---
235
278
 
@@ -238,208 +281,365 @@ Canonical docs: [docs/2.0/overview/architecture.md](docs/2.0/overview/architectu
238
281
  Requires **Node.js 20+**.
239
282
 
240
283
  ```bash
241
- npm install -g @praneeth_54/agentdoctor@2.1.0
242
- # or:
243
- npx @praneeth_54/agentdoctor@2.1.0 --help
284
+ npm install -g @praneeth_54/agentdoctor@3.0.1
285
+ agentdoctor --version # 3.0.1
286
+ agentdoctor --help
244
287
  ```
245
288
 
246
- From source:
289
+ Or without global install:
247
290
 
248
291
  ```bash
249
- git clone https://github.com/pranee54/AgentDoctor.git
250
- cd AgentDoctor
251
- npm install
252
- npm run verify
292
+ npx @praneeth_54/agentdoctor@3.0.1 --help
253
293
  ```
254
294
 
255
295
  ---
256
296
 
257
- ## Quickstart
297
+ ## Five-minute quickstart
258
298
 
259
299
  ```bash
260
- agentdoctor --version # 2.1.0
261
- agentdoctor scan .
262
- agentdoctor scan . --json
263
- agentdoctor fix --dry-run
264
- agentdoctor verify --baseline agentdoctor-report.json
265
-
266
- # Repository Brain proposals (not auto-approved)
267
- agentdoctor init --name "My App" --domain "payments"
268
- agentdoctor brain proposals
269
-
270
- # Intelligence
271
- agentdoctor graph --mode auto --json
272
- agentdoctor impact --json
273
- agentdoctor c4 --json
274
-
275
- # Change assurance
276
- agentdoctor change analyze
277
- agentdoctor change verify
278
- agentdoctor change explain|diff|status
279
- agentdoctor evidence inspect <id>
280
- agentdoctor evidence verify <id>
281
- agentdoctor proof build|inspect|verify|export <id>
282
-
283
- # Architecture / policy / controlled run
284
- agentdoctor architecture init|check|explain
285
- agentdoctor policy check|explain --command "npm test"
286
- agentdoctor run explain --command "npm test"
287
- agentdoctor workspace create|add|list|status|remove
288
-
289
- # MCP (absolute --root required)
290
- agentdoctor brain-mcp --root /ABS/PATH/TO/REPO
291
- agentdoctor mcp --root /ABS/PATH/TO/REPO
292
- ```
300
+ # 1. Install
301
+ npm install -g @praneeth_54/agentdoctor@3.0.1
293
302
 
294
- ### Project AI Agent (2.1 — optional; local RC)
303
+ # 2. Enter YOUR project (not your home folder)
304
+ cd /path/to/my-project
295
305
 
296
- Requires an explicit provider (`AGENTDOCTOR_AI_PROVIDER=mock` or openai-compatible / ollama). Default `none` fails closed for chat.
306
+ # 3. Discover
307
+ agentdoctor start
308
+
309
+ # 4. Understand
310
+ agentdoctor dna .
311
+ agentdoctor graph .
312
+ agentdoctor map .
313
+
314
+ # 5. Ask (works without an LLM — deterministic analyzers)
315
+ agentdoctor ask "Explain my project." .
316
+ agentdoctor ask "How does authentication work?" .
317
+
318
+ # 6. Inspect
319
+ agentdoctor search "TODO" .
320
+ agentdoctor deps .
321
+ agentdoctor security-doctor .
322
+
323
+ # 7. Plan a change (no writes)
324
+ agentdoctor plan "Add a health check endpoint" .
325
+
326
+ # 8. Apply only with explicit approval (example ops JSON; --goal required)
327
+ agentdoctor agent --goal "Add a health check note" --approve --apply \
328
+ --apply-ops '[{"name":"create_file","arguments":{"path":"HEALTH.md","content":"# Health\n"}}]' .
329
+
330
+ # 9. Verify change signals
331
+ agentdoctor change analyze .
332
+ agentdoctor changes .
333
+ ```
334
+
335
+ Optional UI (loopback):
297
336
 
298
337
  ```bash
299
- agentdoctor ask "How does login work?" .
300
- agentdoctor chat .
301
- agentdoctor learn .
302
- agentdoctor learn --viva
303
- agentdoctor plan "Add registration"
304
- # Writes require --approve; model cannot self-approve
305
- agentdoctor agent --goal "Add registration" --approve --apply --apply-ops '[...]' .
338
+ agentdoctor dashboard .
339
+ # → http://127.0.0.1:<port>/
306
340
  ```
307
341
 
308
- Details: [docs/RELEASE_2_1_0.md](docs/RELEASE_2_1_0.md) · [docs/AI_AGENT.md](docs/AI_AGENT.md) · [docs/SECURITY_AGENT.md](docs/SECURITY_AGENT.md)
342
+ ---
309
343
 
310
- CLI reference: [docs/2.0/guides/cli.md](docs/2.0/guides/cli.md) · Change assurance: [docs/2.0.1/change-assurance.md](docs/2.0.1/change-assurance.md)
344
+ ## Command reference
345
+
346
+ All commands below exist in the current CLI (`agentdoctor --help`). Prefer `--json` for scripts.
347
+
348
+ <details>
349
+ <summary><strong>Project & intelligence</strong></summary>
350
+
351
+ | Command | Purpose |
352
+ | ----------------------------------------------------------- | ------------------------------- |
353
+ | `start [path]` | Safe discovery, DNA, Brain init |
354
+ | `dna [path]` | Project DNA fingerprint |
355
+ | `graph [path]` | Intelligence graph |
356
+ | `map [path]` | Software map |
357
+ | `deps` / `dependency` | Dependencies + lockfiles |
358
+ | `search <query>` | Symbol / concept search |
359
+ | `health` / `health-code` | Git / code health |
360
+ | `requirements` / `api` / `database` / `events` / `features` | Lifecycle intelligence |
361
+ | `twin` / `what-if` / `forensic` / `evolution` / `memory` | Twin, impact, forensic, memory |
362
+ | `infra` / `incident` / `org` | Local ops / org catalog |
363
+
364
+ </details>
365
+
366
+ <details>
367
+ <summary><strong>Chat, agent, learning</strong></summary>
368
+
369
+ | Command | Purpose | Safety |
370
+ | ----------------------- | ------------------------------------------- | ------------------------------ |
371
+ | `ask <question> [path]` | One-shot Project Chat | Deterministic if no provider |
372
+ | `chat [path]` | Interactive chat | Needs provider for LLM mode |
373
+ | `plan <goal>` | Plan only | No file edits |
374
+ | `agent` | Tools / apply | `--apply` requires `--approve` |
375
+ | `role-agent` | Role allowlists | Same approval gates |
376
+ | `learn` | Student explain / viva / docs / build modes | Writes need approval |
377
+
378
+ </details>
379
+
380
+ <details>
381
+ <summary><strong>Security, change, evidence</strong></summary>
382
+
383
+ | Command | Purpose |
384
+ | ------------------------------------------------ | -------------------------------- |
385
+ | `scan` / `fix` / `verify` | Agent-config Scan → Fix → Verify |
386
+ | `secrets` / `security-doctor` / `privacy-doctor` | Secrets & technical doctors |
387
+ | `change analyze` / `change verify` | Change assessment & evidence |
388
+ | `evidence` / `proof` | Inspect / integrity |
389
+ | `policy` / `run` / `enforce` | Controlled execution |
390
+ | `self-check` / `eval-lab` / `doctor` | Self / eval / install health |
391
+
392
+ </details>
393
+
394
+ <details>
395
+ <summary><strong>Brain, MCP, dashboard, workspace</strong></summary>
396
+
397
+ | Command | Purpose |
398
+ | ------------------------- | ----------------------------------------------------------- |
399
+ | `brain` | Project Brain CLI |
400
+ | `mcp --root <abs-or-rel>` | Combined Brain + intelligence + agent MCP (STDIO) |
401
+ | `brain-mcp` | Brain-only MCP |
402
+ | `dashboard [path]` | Local read-only SPA (loopback) |
403
+ | `workspace` | Multi-repo local isolation under `.agentdoctor/workspaces/` |
404
+
405
+ </details>
311
406
 
312
407
  ---
313
408
 
314
- ## Project AI Agent (2.1)
409
+ ## AI providers
410
+
411
+ **AI is optional.** Core discovery, DNA, graph, scan/fix/verify, deps, search, security heuristics, evidence, and deterministic `ask` work **without** an API key.
412
+
413
+ Implemented providers ([docs/MODEL_PROVIDERS.md](docs/MODEL_PROVIDERS.md)):
315
414
 
316
- Optional Project AI on top of the 2.0.1 assurance substrate. See [docs/RELEASE_2_1_0.md](docs/RELEASE_2_1_0.md).
415
+ | Provider | Role |
416
+ | --------------------------------- | -------------------------------- |
417
+ | `none` | Default fail-closed for LLM chat |
418
+ | `deterministic` / local analyzers | Project Chat without LLM |
419
+ | `mock` | Tests / demos |
420
+ | `openai-compatible` | OpenAI-compatible HTTP API |
421
+ | `ollama` | Local Ollama-compatible HTTP |
317
422
 
318
- | Piece | Behavior |
319
- | --------- | ------------------------------------------------------------------------- |
320
- | Context | Project evidence with truth labels; repository text is untrusted DATA |
321
- | Tools | Path-safe read/write; commands only via controlled runner (`shell=false`) |
322
- | Approvals | Human/caller `--approve` required for writes; LEARN mode cannot write |
323
- | Verify | Change / evidence / proof signals; `ENGINEERING_CORRECTNESS_NOT_CLAIMED` |
324
- | Limits | Tool calls, iterations, wall time, files modified, context size |
423
+ Configure with `AGENTDOCTOR_AI_PROVIDER`, `AGENTDOCTOR_AI_API_KEY`, `AGENTDOCTOR_AI_BASE_URL`, `AGENTDOCTOR_AI_MODEL`.
325
424
 
326
- Limitations: not an OS sandbox; native Anthropic/Gemini SDKs not implemented; MCP `approved=true` is trusted-caller input (not cryptographic identity); correctness never guaranteed.
425
+ **Not implemented:** native Anthropic / Gemini clients (do not claim).
327
426
 
328
427
  ---
329
428
 
330
- ## Change assurance
429
+ ## MCP
331
430
 
332
- Structured assessment, evidence bundles, and Change Proof **integrity** (not engineering correctness). Optional `--coverage` for coverage-backed / hybrid test impact. See [docs/2.0.1/FINAL_COMPLETION_AUDIT.md](docs/2.0.1/FINAL_COMPLETION_AUDIT.md).
431
+ Connect AgentDoctor to AI coding workflows over STDIO:
333
432
 
334
433
  ```bash
335
- agentdoctor change analyze # ChangeAssessment (verificationStatus: not-run)
336
- agentdoctor change verify # write .agentdoctor/evidence/<id>/ (evidence-produced)
337
- agentdoctor change explain|diff|status
338
- agentdoctor evidence inspect <id> # list artifacts + manifest
339
- agentdoctor evidence verify <id> # SHA-256 check; verified only if all hashes match
340
- agentdoctor proof inspect|verify <id> # integrity; correctnessStatus always NOT_CLAIMED
434
+ agentdoctor mcp --root /absolute/path/to/project
341
435
  ```
342
436
 
343
- `verified` means artifact integrity against the manifest — not that the change is correct or safe. Details: [docs/2.0.1/change-assurance.md](docs/2.0.1/change-assurance.md) · [docs/2.0.1/evidence.md](docs/2.0.1/evidence.md)
437
+ Audited combined server exposes **38 tools** (Brain + intelligence + agent), including project DNA/context/ask, search, file read, planning, change analysis, and controlled writes.
438
+
439
+ **Safety (verified):**
440
+
441
+ - Path / workspace bounds; traversal rejected
442
+ - Writes need trusted `approvalToken` + `planHash` + resource binding
443
+ - Bare `approved: true` is **rejected**
444
+ - `approval_issue` requires `AGENTDOCTOR_MCP_TRUSTED_APPROVE=1`
445
+ - Secret redaction; no unrestricted shell tool
446
+ - Forensic mode blocks write/execute
447
+
448
+ Details: [docs/MCP.md](docs/MCP.md) · [docs/AGENT_APPROVALS.md](docs/AGENT_APPROVALS.md)
344
449
 
345
450
  ---
346
451
 
347
- ## MCP
452
+ ## Security model
348
453
 
349
- AgentDoctor exposes local **STDIO** MCP servers (no API key).
454
+ Repository content is **untrusted data** — never system policy.
350
455
 
351
- | Server | Command | Tools |
352
- | ------------ | ------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
353
- | Brain MCP | `agentdoctor brain-mcp --root <abs>` | `brain_overview`, `brain_query`, `brain_explain`, `brain_trace`, `brain_claims`, `brain_evidence`, `brain_ownership`, `brain_risk`, `brain_delta`, `brain_snapshot` |
354
- | Combined MCP | `agentdoctor mcp --root <abs>` | All `brain_*` tools **plus** intelligence tools below |
456
+ Controls include:
355
457
 
356
- Intelligence tools (combined MCP):
357
- `repo_overview`, `codebase_search`, `symbol_lookup`, `dependency_lookup`, `call_graph_lookup`, `test_impact`, `refactor_impact`, `code_health`, `architecture_info`, `architecture_check`, `knowledge_retrieve`, `policy_evaluate`, `change_analyze`, `proof_inspect`, `evidence_inspect`, `graph_query`
458
+ - Central path safety (traversal, symlinks, workspace escape)
459
+ - Approval-bound mutations (CLI `--approve` / MCP grants)
460
+ - Controlled runner (`shell=false` by default)
461
+ - Secret scanning with **redaction**
462
+ - Forensic read-only mode (`AGENTDOCTOR_FORENSIC_MODE=1`)
463
+ - Prompt-injection treated as data (eval fixture + chat framing)
464
+ - Evidence / audit trails
358
465
 
359
- Guide: [docs/2.0/guides/mcp.md](docs/2.0/guides/mcp.md) · Deep Brain MCP: [docs/mcp/brain-mcp.md](docs/mcp/brain-mcp.md)
466
+ AgentDoctor does **not** claim to be “completely safe,” a legal compliance product, or a commercial SAST replacement.
467
+
468
+ Policy: [SECURITY.md](SECURITY.md) · Model: [docs/SECURITY_MODEL.md](docs/SECURITY_MODEL.md)
360
469
 
361
470
  ---
362
471
 
363
- ## GitHub Action
472
+ ## Truth model
473
+
474
+ | Label | Meaning |
475
+ | ------------ | ----------------------------------------- |
476
+ | **VERIFIED** | Directly supported by repository evidence |
477
+ | **INFERRED** | Derived from available signals |
478
+ | **UNKNOWN** | Insufficient evidence |
479
+ | **EXTERNAL** | Needs systems outside the local repo |
364
480
 
365
- Use AgentDoctor Safety in CI for scan / verify gates. Default npm version input is **`2.1.0`**.
481
+ Honesty is a feature: the system should not invent files, line numbers, or root causes.
482
+
483
+ ---
366
484
 
367
- ```yaml
368
- - uses: pranee54/AgentDoctor@v2.1.0
369
- with:
370
- path: .
371
- version: "2.1.0"
372
- fail-on-severity: critical
485
+ ## Evidence and proof
486
+
487
+ AgentDoctor answers: what changed, what was affected, what evidence exists, what was integrity-checked, and what remains uncertain.
488
+
489
+ ```bash
490
+ agentdoctor change analyze .
491
+ agentdoctor change verify .
492
+ agentdoctor evidence inspect <changeId> .
493
+ agentdoctor proof verify <changeId> .
373
494
  ```
374
495
 
375
- For repository CI against the checked-out build: `version: workspace` (requires `dist/` from `npm run build`).
496
+ **Proof = hash integrity over an evidence bundle.** It is **not** a formal proof of correctness.
376
497
 
377
- Guide: [docs/2.0/guides/github-action.md](docs/2.0/guides/github-action.md) · Action metadata: [`action.yml`](action.yml)
498
+ ---
378
499
 
379
- Marketplace listing: confirm in the GitHub UI if you need Marketplace discovery beyond the Action in this repository.
500
+ ## Architecture (modules)
501
+
502
+ ```text
503
+ CLI / MCP / Dashboard
504
+ │
505
+ ▼
506
+ Agent runtime · Project Chat · Student / roles
507
+ │
508
+ ▼
509
+ Context retrieval · Truth labels
510
+ │
511
+ ▼
512
+ Project Brain · Graph/AST · DNA · Git · Deps · Tests · Security · Twin
513
+ │
514
+ ▼
515
+ Path-safe tools · Approvals · Controlled runner
516
+ │
517
+ ▼
518
+ Change assessment · Evidence · Proof
519
+ ```
520
+
521
+ Primary code: `src/cli`, `src/agent`, `src/product`, `src/intelligence`, `src/mcp`, `src/dashboard`, `src/core`, `src/assurance`, `src/security`.
380
522
 
381
523
  ---
382
524
 
383
- ## Security model
525
+ ## Technology stack
384
526
 
385
- | Control | Behavior |
386
- | ----------- | -------------------------------------------------------------------------- |
387
- | Path safety | MCP / dashboard reject traversal, encoded escapes, hostile URLs |
388
- | Safe Fix | Preflight targets; refuse symlink write-through / non-allowlisted paths |
389
- | Secrets | Opt-in scan; findings and exports redact sensitive patterns |
390
- | Policy | Evaluate-only by default (`executionResult: "not-executed"`) |
391
- | Enforcement | Controlled runner blocks; does **not** claim IDE interception |
392
- | Dashboard | Loopback by default; non-loopback requires explicit opt-in |
393
- | Team auth | Local-dev scrypt + optional OIDC JWT validation — **not** full browser SSO |
527
+ Derived from `package.json` and source:
394
528
 
395
- Threat model: [docs/2.0/overview/security-threat-model.md](docs/2.0/overview/security-threat-model.md) · Trust boundaries: [docs/2.0/overview/trust-boundaries.md](docs/2.0/overview/trust-boundaries.md)
529
+ | Area | Technology |
530
+ | ----------- | ------------------------------------------------- |
531
+ | Language | TypeScript (ESM) |
532
+ | Runtime | Node.js ≥ 20 |
533
+ | CLI | Commander |
534
+ | Tests | Vitest |
535
+ | Build | `tsc` |
536
+ | MCP | `@modelcontextprotocol/sdk` |
537
+ | Dashboard | Local Node HTTP + embedded SPA |
538
+ | AST (TS/JS) | TypeScript compiler API |
539
+ | Packaging | npm (`files`: `dist`, README, LICENSE, CHANGELOG) |
540
+ | License | MIT |
396
541
 
397
542
  ---
398
543
 
399
- ## What AgentDoctor does not do
544
+ ## Verification
545
+
546
+ **AgentDoctor 3.0** — local acceptance evidence:
400
547
 
401
- - Full browser OAuth / production IdP login UX (JWT validation library path exists; redirect flow is experimental)
402
- - Complete multi-language AST (Java / Kotlin / Rust / Dart / Go extractors external or unsupported)
403
- - Coverage as universal ground truth without a coverage file / test map
404
- - IDE / agent process interception (external host APIs)
405
- - Production multi-tenant cloud / managed hosting in this package
406
- - Guaranteed autonomous command execution of “allowed” policies
407
- - Treating inferred C4 / heuristic impact as approved architecture truth
408
- - Shipping full `docs/2.0.1/` inside the npm tarball (Option B: README + GitHub docs)
548
+ | Gate | Result |
549
+ | --------------------------------------- | -------------------------------------------------------- |
550
+ | Formal / release / product acceptance | **PASS** (maintainers: [docs/internal/](docs/internal/)) |
551
+ | `npm run verify` | **627/627** tests, typecheck, lint, format, build |
552
+ | Clean `npm pack` install | PASS |
553
+ | MCP | **38** tools; approval + path checks |
554
+ | Dashboard / API | Real project JSON (not fake cards) |
555
+ | Security / forensic / eval / self-check | PASS |
556
+ | P0 / P1 blockers | **0** |
409
557
 
410
- Full list: [docs/2.0.1/limitations.md](docs/2.0.1/limitations.md) · [docs/2.0/overview/known-limitations.md](docs/2.0/overview/known-limitations.md)
558
+ Reproduce:
559
+
560
+ ```bash
561
+ npm run verify
562
+ ```
411
563
 
412
564
  ---
413
565
 
414
- ## Roadmap note: Change Proof
566
+ ## Limitations
415
567
 
416
- Change assessment, evidence, and proof **integrity** shipped in 2.0.1. `correctnessStatus` is always `ENGINEERING_CORRECTNESS_NOT_CLAIMED`. Broader compliance / team-scale proof UX remains planned.
568
+ Honesty is part of the product. Read **[docs/LIMITATIONS.md](docs/LIMITATIONS.md)**.
417
569
 
418
- See [ROADMAP.md](ROADMAP.md) · [docs/2.0.1/limitations.md](docs/2.0.1/limitations.md) · [docs/2.0.1/FINAL_COMPLETION_AUDIT.md](docs/2.0.1/FINAL_COMPLETION_AUDIT.md).
570
+ Notable boundaries:
571
+
572
+ - Live Kubernetes / APM / enterprise IdP → **EXTERNAL**
573
+ - Neural embeddings / commercial SAST → **EXTERNAL**
574
+ - Full compiler-grade semantics for all languages → **EXTERNAL** where adapters are line scanners
575
+ - Optional LLM providers → configure explicitly; core stays useful without them
576
+ - Proof ≠ engineering correctness
577
+
578
+ Post-acceptance ideas for later releases: maintainers see [docs/internal/POST_3_0_BACKLOG.md](docs/internal/POST_3_0_BACKLOG.md).
419
579
 
420
580
  ---
421
581
 
422
- ## Documentation map
582
+ ## Roadmap
583
+
584
+ | Track | Meaning |
585
+ | --------------------- | ------------------------------------------------------------------------- |
586
+ | **3.0.0 (released)** | Original public release (`v3.0.0` → `c21faf1`) |
587
+ | **3.0.1 (candidate)** | Freeze remediation / ownership & security hardening follow-up (`319810a`) |
588
+ | **Coming soon** | Maturity, language depth, runtime adapters, DX — not promised ship dates |
423
589
 
424
- | Audience | Start here |
425
- | -------------------------------------- | ------------------------------------------------------------------------------------------------------------------------- |
426
- | Product / 2.0.1 | [docs/2.0.1/README.md](docs/2.0.1/README.md) |
427
- | Product / 2.0 | [docs/2.0/README.md](docs/2.0/README.md) |
428
- | Capabilities / readiness | [capabilities](docs/2.0/overview/capabilities.md) · [readiness](docs/2.0/overview/readiness-matrix.md) |
429
- | Guides | [docs/2.0/guides/](docs/2.0/guides/) |
430
- | Reference (rules, scoring, exit codes) | [docs/reference/](docs/reference/) |
431
- | Contributing | [CONTRIBUTING.md](CONTRIBUTING.md) · [docs/development/development.md](docs/development/development.md) |
432
- | Changelog | [CHANGELOG.md](CHANGELOG.md) |
433
- | Release evidence | [FINAL_RELEASE_AUDIT](docs/2.0.1/FINAL_RELEASE_AUDIT.md) · [FINAL_COMPLETION_AUDIT](docs/2.0.1/FINAL_COMPLETION_AUDIT.md) |
590
+ ---
591
+
592
+ ## Documentation
593
+
594
+ Full index: **[docs/README.md](docs/README.md)**
595
+
596
+ | Topic | Link |
597
+ | ---------------- | --------------------------------------------------------------------- |
598
+ | Product | [docs/PRODUCT.md](docs/PRODUCT.md) |
599
+ | Project Chat | [docs/PROJECT_CHAT.md](docs/PROJECT_CHAT.md) |
600
+ | AI Agent | [docs/AI_AGENT.md](docs/AI_AGENT.md) |
601
+ | Student mode | [docs/STUDENT_MODE.md](docs/STUDENT_MODE.md) |
602
+ | MCP | [docs/MCP.md](docs/MCP.md) |
603
+ | Approvals | [docs/AGENT_APPROVALS.md](docs/AGENT_APPROVALS.md) |
604
+ | Security model | [docs/SECURITY_MODEL.md](docs/SECURITY_MODEL.md) |
605
+ | Evidence / Proof | [docs/EVIDENCE.md](docs/EVIDENCE.md) · [docs/PROOF.md](docs/PROOF.md) |
606
+ | Project Brain | [docs/PROJECT_BRAIN.md](docs/PROJECT_BRAIN.md) |
607
+ | Limitations | [docs/LIMITATIONS.md](docs/LIMITATIONS.md) |
608
+ | Feature guides | [docs/guides/features/](docs/guides/features/) |
609
+ | Contributing | [CONTRIBUTING.md](CONTRIBUTING.md) |
610
+ | Security policy | [SECURITY.md](SECURITY.md) |
611
+ | Code of conduct | [CODE_OF_CONDUCT.md](CODE_OF_CONDUCT.md) |
612
+ | Changelog | [CHANGELOG.md](CHANGELOG.md) |
434
613
 
435
614
  ---
436
615
 
437
616
  ## Contributing
438
617
 
439
- See [CONTRIBUTING.md](CONTRIBUTING.md). Prefer evidence-backed PRs, honest status labels, and no inflated capability claims.
618
+ ```bash
619
+ git clone https://github.com/pranee54/AgentDoctor.git
620
+ cd AgentDoctor
621
+ npm install
622
+ npm run verify
623
+ ```
624
+
625
+ See [CONTRIBUTING.md](CONTRIBUTING.md). Issues and PRs welcome via GitHub templates.
440
626
 
441
627
  ---
442
628
 
443
629
  ## License
444
630
 
445
- MIT — see [LICENSE](LICENSE).
631
+ [MIT](LICENSE) © AgentDoctor Contributors
632
+
633
+ ---
634
+
635
+ ## GitHub discoverability (maintainers)
636
+
637
+ Suggested repository description:
638
+
639
+ > Project intelligence and assurance for software — understand, ask, plan, approve, change, test, secure, verify, and prove. Local-first. MCP-ready.
640
+
641
+ Suggested topics: `software-engineering`, `developer-tools`, `code-intelligence`, `ai-agents`, `mcp`, `static-analysis`, `developer-experience`, `security`, `testing`, `typescript`
642
+
643
+ ---
644
+
645
+ **Try it on a real project in five minutes.** If something is UNKNOWN, that is intentional — AgentDoctor should show the boundary, not invent certainty.