@praneeth_54/agentdoctor 2.0.1 → 3.0.0
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.
- package/CHANGELOG.md +123 -1
- package/README.md +510 -260
- package/dist/agent/approvals.d.ts +24 -0
- package/dist/agent/approvals.js +64 -0
- package/dist/agent/chat/deterministic.d.ts +6 -0
- package/dist/agent/chat/deterministic.js +180 -0
- package/dist/agent/chat/index.d.ts +7 -0
- package/dist/agent/chat/index.js +5 -0
- package/dist/agent/chat/memory.d.ts +44 -0
- package/dist/agent/chat/memory.js +103 -0
- package/dist/agent/chat/project-summary.d.ts +16 -0
- package/dist/agent/chat/project-summary.js +70 -0
- package/dist/agent/chat/prompts.d.ts +6 -0
- package/dist/agent/chat/prompts.js +39 -0
- package/dist/agent/chat/response.d.ts +19 -0
- package/dist/agent/chat/response.js +109 -0
- package/dist/agent/chat/service.d.ts +42 -0
- package/dist/agent/chat/service.js +246 -0
- package/dist/agent/chat/types.d.ts +48 -0
- package/dist/agent/chat/types.js +1 -0
- package/dist/agent/context/retrieve.d.ts +21 -0
- package/dist/agent/context/retrieve.js +117 -0
- package/dist/agent/context/truth.d.ts +6 -0
- package/dist/agent/context/truth.js +19 -0
- package/dist/agent/context/types.d.ts +23 -0
- package/dist/agent/context/types.js +4 -0
- package/dist/agent/index.d.ts +28 -0
- package/dist/agent/index.js +15 -0
- package/dist/agent/loop.d.ts +53 -0
- package/dist/agent/loop.js +253 -0
- package/dist/agent/modes.d.ts +18 -0
- package/dist/agent/modes.js +102 -0
- package/dist/agent/plan.d.ts +30 -0
- package/dist/agent/plan.js +121 -0
- package/dist/agent/roles.d.ts +12 -0
- package/dist/agent/roles.js +138 -0
- package/dist/agent/runtime.d.ts +83 -0
- package/dist/agent/runtime.js +293 -0
- package/dist/agent/state.d.ts +30 -0
- package/dist/agent/state.js +95 -0
- package/dist/agent/student.d.ts +56 -0
- package/dist/agent/student.js +230 -0
- package/dist/agent/tools/execute.d.ts +20 -0
- package/dist/agent/tools/execute.js +365 -0
- package/dist/agent/tools/index.d.ts +6 -0
- package/dist/agent/tools/index.js +5 -0
- package/dist/agent/tools/registry.d.ts +7 -0
- package/dist/agent/tools/registry.js +212 -0
- package/dist/agent/tools/run.d.ts +24 -0
- package/dist/agent/tools/run.js +44 -0
- package/dist/agent/tools/types.d.ts +32 -0
- package/dist/agent/tools/types.js +10 -0
- package/dist/agent/tools/write.d.ts +24 -0
- package/dist/agent/tools/write.js +121 -0
- package/dist/agent/verify.d.ts +29 -0
- package/dist/agent/verify.js +210 -0
- package/dist/ai/config.d.ts +22 -0
- package/dist/ai/config.js +69 -0
- package/dist/ai/index.d.ts +17 -0
- package/dist/ai/index.js +52 -0
- package/dist/ai/providers/mock.d.ts +20 -0
- package/dist/ai/providers/mock.js +84 -0
- package/dist/ai/providers/none.d.ts +6 -0
- package/dist/ai/providers/none.js +23 -0
- package/dist/ai/providers/openai-compatible.d.ts +21 -0
- package/dist/ai/providers/openai-compatible.js +151 -0
- package/dist/ai/redact.d.ts +9 -0
- package/dist/ai/redact.js +61 -0
- package/dist/ai/types.d.ts +71 -0
- package/dist/ai/types.js +6 -0
- package/dist/cli/commands/agent.d.ts +29 -0
- package/dist/cli/commands/agent.js +164 -0
- package/dist/cli/commands/chat.d.ts +14 -0
- package/dist/cli/commands/chat.js +153 -0
- package/dist/cli/commands/learn.d.ts +12 -0
- package/dist/cli/commands/learn.js +107 -0
- package/dist/cli/commands/product.d.ts +19 -0
- package/dist/cli/commands/product.js +147 -0
- package/dist/cli/commands/start.d.ts +15 -0
- package/dist/cli/commands/start.js +80 -0
- package/dist/cli/program.js +233 -0
- package/dist/constants.d.ts +1 -1
- package/dist/constants.js +1 -1
- package/dist/dashboard/server.d.ts +6 -0
- package/dist/dashboard/server.js +333 -43
- package/dist/enforcement/runner.d.ts +5 -0
- package/dist/enforcement/runner.js +51 -4
- package/dist/index.d.ts +17 -0
- package/dist/index.js +10 -0
- package/dist/intelligence/graph/build.js +36 -8
- package/dist/intelligence/resolve/imports.js +1 -1
- package/dist/languages/dart.d.ts +10 -0
- package/dist/languages/dart.js +99 -0
- package/dist/languages/go.d.ts +13 -7
- package/dist/languages/go.js +91 -26
- package/dist/languages/index.d.ts +5 -1
- package/dist/languages/index.js +13 -36
- package/dist/languages/java.d.ts +10 -0
- package/dist/languages/java.js +80 -0
- package/dist/languages/kotlin.d.ts +10 -0
- package/dist/languages/kotlin.js +85 -0
- package/dist/languages/php.d.ts +1 -0
- package/dist/languages/php.js +11 -2
- package/dist/languages/python.d.ts +6 -2
- package/dist/languages/python.js +39 -9
- package/dist/languages/rust.d.ts +10 -0
- package/dist/languages/rust.js +93 -0
- package/dist/languages/types.d.ts +4 -3
- package/dist/mcp/agent/registry.d.ts +13 -0
- package/dist/mcp/agent/registry.js +320 -0
- package/dist/mcp/agentdoctor/server.js +8 -1
- package/dist/mcp/intelligence/handlers.d.ts +3 -0
- package/dist/mcp/intelligence/handlers.js +28 -0
- package/dist/mcp/intelligence/registry.d.ts +1 -1
- package/dist/mcp/intelligence/registry.js +30 -1
- package/dist/product/api/doctor.d.ts +14 -0
- package/dist/product/api/doctor.js +185 -0
- package/dist/product/api/openapi.d.ts +7 -0
- package/dist/product/api/openapi.js +122 -0
- package/dist/product/approval/model.d.ts +30 -0
- package/dist/product/approval/model.js +64 -0
- package/dist/product/approval/session.d.ts +49 -0
- package/dist/product/approval/session.js +134 -0
- package/dist/product/database/doctor.d.ts +30 -0
- package/dist/product/database/doctor.js +184 -0
- package/dist/product/decisions/ledger.d.ts +24 -0
- package/dist/product/decisions/ledger.js +110 -0
- package/dist/product/deps/analyze.d.ts +46 -0
- package/dist/product/deps/analyze.js +137 -0
- package/dist/product/deps/lockfiles.d.ts +25 -0
- package/dist/product/deps/lockfiles.js +200 -0
- package/dist/product/discovery/roots.d.ts +42 -0
- package/dist/product/discovery/roots.js +215 -0
- package/dist/product/dna/build.d.ts +50 -0
- package/dist/product/dna/build.js +255 -0
- package/dist/product/eval/lab.d.ts +17 -0
- package/dist/product/eval/lab.js +218 -0
- package/dist/product/events/doctor.d.ts +21 -0
- package/dist/product/events/doctor.js +147 -0
- package/dist/product/evidence-scan.d.ts +12 -0
- package/dist/product/evidence-scan.js +46 -0
- package/dist/product/evolution/timeline.d.ts +29 -0
- package/dist/product/evolution/timeline.js +123 -0
- package/dist/product/features/intelligence.d.ts +23 -0
- package/dist/product/features/intelligence.js +158 -0
- package/dist/product/forensic/mode.d.ts +25 -0
- package/dist/product/forensic/mode.js +70 -0
- package/dist/product/graph/enrich-languages.d.ts +20 -0
- package/dist/product/graph/enrich-languages.js +193 -0
- package/dist/product/health/code-health.d.ts +20 -0
- package/dist/product/health/code-health.js +149 -0
- package/dist/product/index.d.ts +69 -0
- package/dist/product/index.js +35 -0
- package/dist/product/ledger/change-ledger.d.ts +23 -0
- package/dist/product/ledger/change-ledger.js +64 -0
- package/dist/product/map/software-map.d.ts +17 -0
- package/dist/product/map/software-map.js +95 -0
- package/dist/product/memory/institutional.d.ts +16 -0
- package/dist/product/memory/institutional.js +87 -0
- package/dist/product/ops/incident.d.ts +20 -0
- package/dist/product/ops/incident.js +61 -0
- package/dist/product/ops/infra.d.ts +15 -0
- package/dist/product/ops/infra.js +112 -0
- package/dist/product/org/model.d.ts +34 -0
- package/dist/product/org/model.js +195 -0
- package/dist/product/privacy/doctor.d.ts +13 -0
- package/dist/product/privacy/doctor.js +90 -0
- package/dist/product/requirements/trace.d.ts +21 -0
- package/dist/product/requirements/trace.js +166 -0
- package/dist/product/search/index.d.ts +29 -0
- package/dist/product/search/index.js +116 -0
- package/dist/product/search/software-search.d.ts +19 -0
- package/dist/product/search/software-search.js +100 -0
- package/dist/product/security/doctor.d.ts +23 -0
- package/dist/product/security/doctor.js +124 -0
- package/dist/product/self/diagnose.d.ts +15 -0
- package/dist/product/self/diagnose.js +82 -0
- package/dist/product/techdebt/roadmap.d.ts +20 -0
- package/dist/product/techdebt/roadmap.js +118 -0
- package/dist/product/testbrain/analyze.d.ts +29 -0
- package/dist/product/testbrain/analyze.js +129 -0
- package/dist/product/truth.d.ts +12 -0
- package/dist/product/truth.js +30 -0
- package/dist/product/twin/digital-twin.d.ts +23 -0
- package/dist/product/twin/digital-twin.js +52 -0
- package/dist/product/twin/store.d.ts +21 -0
- package/dist/product/twin/store.js +70 -0
- package/dist/product/whatif/engine.d.ts +28 -0
- package/dist/product/whatif/engine.js +70 -0
- package/dist/security/paths.js +43 -15
- package/dist/utils/fs.js +10 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,214 +1,278 @@
|
|
|
1
1
|
# AgentDoctor
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
### The intelligence and assurance layer for software projects.
|
|
4
4
|
|
|
5
|
-
Understand your codebase
|
|
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
|
[](https://www.npmjs.com/package/@praneeth_54/agentdoctor)
|
|
8
10
|
[](https://github.com/pranee54/AgentDoctor/actions/workflows/ci.yml)
|
|
9
11
|
[](https://nodejs.org)
|
|
10
|
-
[](LICENSE)
|
|
11
13
|
|
|
12
|
-
**
|
|
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))
|
|
13
16
|
|
|
14
|
-
[Install](#install) · [
|
|
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)
|
|
15
18
|
|
|
16
19
|
---
|
|
17
20
|
|
|
18
|
-
## What AgentDoctor
|
|
21
|
+
## What is AgentDoctor?
|
|
22
|
+
|
|
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.
|
|
24
|
+
|
|
25
|
+
Most tools answer one slice of the problem:
|
|
26
|
+
|
|
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 |
|
|
19
34
|
|
|
20
|
-
AgentDoctor
|
|
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:
|
|
21
36
|
|
|
22
|
-
|
|
37
|
+
```text
|
|
38
|
+
UNDERSTAND → ASK → PLAN → APPROVE → CHANGE → TEST → SECURE → VERIFY → PROVE
|
|
39
|
+
```
|
|
23
40
|
|
|
24
|
-
|
|
41
|
+
It is **not** “another chatbot,” a Cursor clone, a generic coding agent, or a claim of full autonomy.
|
|
25
42
|
|
|
26
|
-
|
|
43
|
+
**Invariant**
|
|
27
44
|
|
|
28
|
-
|
|
45
|
+
```text
|
|
46
|
+
THE MODEL REASONS.
|
|
47
|
+
AGENTDOCTOR PROVIDES PROJECT CONTEXT.
|
|
48
|
+
AGENTDOCTOR CONTROLS TOOLS.
|
|
49
|
+
AGENTDOCTOR VERIFIES RESULTS.
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
The model is **not** the source of truth. Repository evidence is.
|
|
29
53
|
|
|
30
54
|
---
|
|
31
55
|
|
|
32
|
-
## Why
|
|
56
|
+
## Why it exists
|
|
33
57
|
|
|
34
|
-
|
|
58
|
+
AI tools can write code quickly. Engineering still needs answers to:
|
|
35
59
|
|
|
36
|
-
-
|
|
37
|
-
-
|
|
38
|
-
-
|
|
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?
|
|
39
68
|
|
|
40
|
-
|
|
69
|
+
AgentDoctor exists for that loop — locally, inspectably, with explicit truth labels.
|
|
41
70
|
|
|
42
|
-
|
|
43
|
-
| ------------------ | ------------------------------ |
|
|
44
|
-
| Source structure | AST / imports / modules |
|
|
45
|
-
| Dependencies | manifests / lockfiles |
|
|
46
|
-
| History | Git |
|
|
47
|
-
| Architecture | docs / conventions / inference |
|
|
48
|
-
| Tests | test trees / naming heuristics |
|
|
49
|
-
| Policy | CI rules / allowlists |
|
|
50
|
-
| Decisions | ADRs / RFCs / tribal knowledge |
|
|
51
|
-
| Secrets / exposure | config files / ignore rules |
|
|
71
|
+
---
|
|
52
72
|
|
|
53
|
-
|
|
73
|
+
## How it works
|
|
54
74
|
|
|
55
75
|
```text
|
|
56
|
-
Developer / AI
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
│
|
|
66
|
-
│
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
│
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
│
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
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
|
|
77
98
|
```
|
|
78
99
|
|
|
79
100
|
---
|
|
80
101
|
|
|
81
|
-
##
|
|
102
|
+
## Who is it for?
|
|
82
103
|
|
|
83
|
-
|
|
104
|
+
### Students
|
|
84
105
|
|
|
85
|
-
|
|
106
|
+
College / B.Tech / final-year projects, inherited repos, viva prep, documentation.
|
|
86
107
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
| Change / test / refactor impact | PARTIAL |
|
|
95
|
-
| 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
|
+
```
|
|
96
115
|
|
|
97
|
-
|
|
116
|
+
Use **Build With Me** only with explicit approval (`--approve`) before writes.
|
|
98
117
|
|
|
99
|
-
|
|
100
|
-
| ------------------------------------------------------------- | --------- |
|
|
101
|
-
| Project Brain store + evidence-backed claims | SUPPORTED |
|
|
102
|
-
| Repository Brain init / proposal review (never auto-approved) | PARTIAL |
|
|
103
|
-
| Governed knowledge + abstention on retrieve | PARTIAL |
|
|
104
|
-
| Provenance envelopes on Brain MCP tools | SUPPORTED |
|
|
118
|
+
### Developers
|
|
105
119
|
|
|
106
|
-
|
|
120
|
+
Inherited codebases, impact analysis, deps, architecture, change assurance.
|
|
107
121
|
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
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
|
+
```
|
|
115
131
|
|
|
116
|
-
###
|
|
132
|
+
### AI-assisted developers
|
|
117
133
|
|
|
118
|
-
|
|
119
|
-
| -------------------------------------------------------- | --------------------- |
|
|
120
|
-
| Scan → Safe Fix → Verify | SUPPORTED |
|
|
121
|
-
| Policy gates (`--min-score`, severity, rule, verify-new) | SUPPORTED |
|
|
122
|
-
| Evaluate-only policy / controlled enforcement runner | PARTIAL |
|
|
123
|
-
| Secret scan (redacted findings) + export redaction | PARTIAL |
|
|
124
|
-
| Path-safety for MCP / dashboard | PARTIAL |
|
|
125
|
-
| 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.
|
|
126
135
|
|
|
127
|
-
|
|
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
|
+
```
|
|
128
141
|
|
|
129
|
-
|
|
130
|
-
| ------------------------------------------------------- | -------------------------- |
|
|
131
|
-
| Change assurance assessment + evidence bundles | PARTIAL |
|
|
132
|
-
| Evidence hash verify (`verified` = integrity only) | SUPPORTED |
|
|
133
|
-
| Unit / integration / MCP STDIO tests (`npm run verify`) | SUPPORTED |
|
|
134
|
-
| Packed CLI clean-install smoke | SUPPORTED |
|
|
135
|
-
| Reproducible AST perf harness | PARTIAL (synthetic sample) |
|
|
142
|
+
### Security / reviewers
|
|
136
143
|
|
|
137
|
-
|
|
144
|
+
Secrets (redacted), technical security heuristics, forensic read-only mode, path/approval controls, evidence.
|
|
138
145
|
|
|
139
|
-
|
|
146
|
+
```bash
|
|
147
|
+
agentdoctor secrets .
|
|
148
|
+
agentdoctor security-doctor .
|
|
149
|
+
AGENTDOCTOR_FORENSIC_MODE=1 agentdoctor forensic .
|
|
150
|
+
agentdoctor evidence verify <changeId> .
|
|
151
|
+
```
|
|
140
152
|
|
|
141
|
-
|
|
153
|
+
### Teams / owners
|
|
142
154
|
|
|
143
|
-
|
|
155
|
+
Local project DNA, twin snapshots, decisions/ADRs, org catalog (local JSON — not enterprise SSO).
|
|
144
156
|
|
|
145
|
-
```
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
→ Policy
|
|
151
|
-
→ Change
|
|
152
|
-
→ Verification
|
|
153
|
-
→ Evidence
|
|
157
|
+
```bash
|
|
158
|
+
agentdoctor twin .
|
|
159
|
+
agentdoctor decisions .
|
|
160
|
+
agentdoctor org .
|
|
161
|
+
agentdoctor dashboard .
|
|
154
162
|
```
|
|
155
163
|
|
|
156
|
-
|
|
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 |
|
|
157
244
|
|
|
158
245
|
---
|
|
159
246
|
|
|
160
|
-
##
|
|
247
|
+
## Not just a coding agent
|
|
248
|
+
|
|
249
|
+
A coding agent can modify files. AgentDoctor is built for the full loop:
|
|
161
250
|
|
|
162
251
|
```text
|
|
163
|
-
|
|
164
|
-
│
|
|
165
|
-
├── Repository Intelligence
|
|
166
|
-
│ ├── AST (TS/JS)
|
|
167
|
-
│ ├── Graph
|
|
168
|
-
│ ├── Git
|
|
169
|
-
│ └── Impact
|
|
170
|
-
│
|
|
171
|
-
├── Engineering Knowledge
|
|
172
|
-
│ ├── Brain
|
|
173
|
-
│ ├── Governance
|
|
174
|
-
│ └── Provenance
|
|
175
|
-
│
|
|
176
|
-
├── Safety
|
|
177
|
-
│ ├── Scanner
|
|
178
|
-
│ ├── Safe Fix
|
|
179
|
-
│ ├── Secrets
|
|
180
|
-
│ └── Policies
|
|
181
|
-
│
|
|
182
|
-
├── Agent Interface
|
|
183
|
-
│ ├── MCP (brain-mcp / mcp)
|
|
184
|
-
│ ├── CLI
|
|
185
|
-
│ ├── API / dashboard
|
|
186
|
-
│ └── Adapters
|
|
187
|
-
│
|
|
188
|
-
└── Verification
|
|
189
|
-
├── Tests
|
|
190
|
-
├── Reports
|
|
191
|
-
└── Release validation
|
|
252
|
+
UNDERSTAND → PLAN → APPROVE → CHANGE → TEST → SECURE → VERIFY → PROVE
|
|
192
253
|
```
|
|
193
254
|
|
|
194
|
-
|
|
255
|
+
**Don't just generate a change. Understand the project and verify the change.**
|
|
256
|
+
|
|
257
|
+
Proof means **hash integrity over evidence**, with:
|
|
195
258
|
|
|
196
|
-
|
|
259
|
+
`ENGINEERING_CORRECTNESS_NOT_CLAIMED`
|
|
197
260
|
|
|
198
261
|
---
|
|
199
262
|
|
|
200
|
-
##
|
|
263
|
+
## Workflow: “Add password reset”
|
|
201
264
|
|
|
202
|
-
1.
|
|
203
|
-
2.
|
|
204
|
-
3.
|
|
205
|
-
4.
|
|
206
|
-
5.
|
|
207
|
-
6.
|
|
208
|
-
7.
|
|
209
|
-
8.
|
|
210
|
-
9.
|
|
211
|
-
|
|
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
|
|
274
|
+
|
|
275
|
+
Student path: `learn` → ask → viva → docs → Build With Me (with `--approve`).
|
|
212
276
|
|
|
213
277
|
---
|
|
214
278
|
|
|
@@ -217,178 +281,364 @@ Canonical docs: [docs/2.0/overview/architecture.md](docs/2.0/overview/architectu
|
|
|
217
281
|
Requires **Node.js 20+**.
|
|
218
282
|
|
|
219
283
|
```bash
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
# npm install /path/to/praneeth_54-agentdoctor-2.0.1.tgz
|
|
224
|
-
npx @praneeth_54/agentdoctor@2.0.1 --help # after publish
|
|
284
|
+
npm install -g @praneeth_54/agentdoctor@3.0.0
|
|
285
|
+
agentdoctor --version # 3.0.0
|
|
286
|
+
agentdoctor --help
|
|
225
287
|
```
|
|
226
288
|
|
|
227
|
-
|
|
289
|
+
Or without global install:
|
|
228
290
|
|
|
229
291
|
```bash
|
|
230
|
-
|
|
231
|
-
cd AgentDoctor
|
|
232
|
-
npm install
|
|
233
|
-
npm run verify
|
|
292
|
+
npx @praneeth_54/agentdoctor@3.0.0 --help
|
|
234
293
|
```
|
|
235
294
|
|
|
236
295
|
---
|
|
237
296
|
|
|
238
|
-
##
|
|
297
|
+
## Five-minute quickstart
|
|
298
|
+
|
|
299
|
+
```bash
|
|
300
|
+
# 1. Install
|
|
301
|
+
npm install -g @praneeth_54/agentdoctor@3.0.0
|
|
302
|
+
|
|
303
|
+
# 2. Enter YOUR project (not your home folder)
|
|
304
|
+
cd /path/to/my-project
|
|
305
|
+
|
|
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):
|
|
239
336
|
|
|
240
337
|
```bash
|
|
241
|
-
agentdoctor
|
|
242
|
-
|
|
243
|
-
agentdoctor scan . --json
|
|
244
|
-
agentdoctor fix --dry-run
|
|
245
|
-
agentdoctor verify --baseline agentdoctor-report.json
|
|
246
|
-
|
|
247
|
-
# Repository Brain proposals (not auto-approved)
|
|
248
|
-
agentdoctor init --name "My App" --domain "payments"
|
|
249
|
-
agentdoctor brain proposals
|
|
250
|
-
|
|
251
|
-
# Intelligence
|
|
252
|
-
agentdoctor graph --mode auto --json
|
|
253
|
-
agentdoctor impact --json
|
|
254
|
-
agentdoctor c4 --json
|
|
255
|
-
|
|
256
|
-
# Change assurance
|
|
257
|
-
agentdoctor change analyze
|
|
258
|
-
agentdoctor change verify
|
|
259
|
-
agentdoctor change explain|diff|status
|
|
260
|
-
agentdoctor evidence inspect <id>
|
|
261
|
-
agentdoctor evidence verify <id>
|
|
262
|
-
agentdoctor proof build|inspect|verify|export <id>
|
|
263
|
-
|
|
264
|
-
# Architecture / policy / controlled run
|
|
265
|
-
agentdoctor architecture init|check|explain
|
|
266
|
-
agentdoctor policy check|explain --command "npm test"
|
|
267
|
-
agentdoctor run explain --command "npm test"
|
|
268
|
-
agentdoctor workspace create|add|list|status|remove
|
|
269
|
-
|
|
270
|
-
# MCP (absolute --root required)
|
|
271
|
-
agentdoctor brain-mcp --root /ABS/PATH/TO/REPO
|
|
272
|
-
agentdoctor mcp --root /ABS/PATH/TO/REPO
|
|
338
|
+
agentdoctor dashboard .
|
|
339
|
+
# → http://127.0.0.1:<port>/
|
|
273
340
|
```
|
|
274
341
|
|
|
275
|
-
|
|
342
|
+
---
|
|
343
|
+
|
|
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>
|
|
276
406
|
|
|
277
407
|
---
|
|
278
408
|
|
|
279
|
-
##
|
|
409
|
+
## AI providers
|
|
280
410
|
|
|
281
|
-
|
|
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)):
|
|
414
|
+
|
|
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 |
|
|
422
|
+
|
|
423
|
+
Configure with `AGENTDOCTOR_AI_PROVIDER`, `AGENTDOCTOR_AI_API_KEY`, `AGENTDOCTOR_AI_BASE_URL`, `AGENTDOCTOR_AI_MODEL`.
|
|
424
|
+
|
|
425
|
+
**Not implemented:** native Anthropic / Gemini clients (do not claim).
|
|
426
|
+
|
|
427
|
+
---
|
|
428
|
+
|
|
429
|
+
## MCP
|
|
430
|
+
|
|
431
|
+
Connect AgentDoctor to AI coding workflows over STDIO:
|
|
282
432
|
|
|
283
433
|
```bash
|
|
284
|
-
agentdoctor
|
|
285
|
-
agentdoctor change verify # write .agentdoctor/evidence/<id>/ (evidence-produced)
|
|
286
|
-
agentdoctor change explain|diff|status
|
|
287
|
-
agentdoctor evidence inspect <id> # list artifacts + manifest
|
|
288
|
-
agentdoctor evidence verify <id> # SHA-256 check; verified only if all hashes match
|
|
289
|
-
agentdoctor proof inspect|verify <id> # integrity; correctnessStatus always NOT_CLAIMED
|
|
434
|
+
agentdoctor mcp --root /absolute/path/to/project
|
|
290
435
|
```
|
|
291
436
|
|
|
292
|
-
|
|
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)
|
|
293
449
|
|
|
294
450
|
---
|
|
295
451
|
|
|
296
|
-
##
|
|
452
|
+
## Security model
|
|
297
453
|
|
|
298
|
-
|
|
454
|
+
Repository content is **untrusted data** — never system policy.
|
|
299
455
|
|
|
300
|
-
|
|
301
|
-
| ------------ | ------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
302
|
-
| 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` |
|
|
303
|
-
| Combined MCP | `agentdoctor mcp --root <abs>` | All `brain_*` tools **plus** intelligence tools below |
|
|
456
|
+
Controls include:
|
|
304
457
|
|
|
305
|
-
|
|
306
|
-
|
|
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
|
|
307
465
|
|
|
308
|
-
|
|
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)
|
|
309
469
|
|
|
310
470
|
---
|
|
311
471
|
|
|
312
|
-
##
|
|
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 |
|
|
313
480
|
|
|
314
|
-
|
|
481
|
+
Honesty is a feature: the system should not invent files, line numbers, or root causes.
|
|
482
|
+
|
|
483
|
+
---
|
|
315
484
|
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
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> .
|
|
322
494
|
```
|
|
323
495
|
|
|
324
|
-
|
|
496
|
+
**Proof = hash integrity over an evidence bundle.** It is **not** a formal proof of correctness.
|
|
325
497
|
|
|
326
|
-
|
|
498
|
+
---
|
|
499
|
+
|
|
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
|
+
```
|
|
327
520
|
|
|
328
|
-
|
|
521
|
+
Primary code: `src/cli`, `src/agent`, `src/product`, `src/intelligence`, `src/mcp`, `src/dashboard`, `src/core`, `src/assurance`, `src/security`.
|
|
329
522
|
|
|
330
523
|
---
|
|
331
524
|
|
|
332
|
-
##
|
|
525
|
+
## Technology stack
|
|
333
526
|
|
|
334
|
-
|
|
335
|
-
| ----------- | -------------------------------------------------------------------------- |
|
|
336
|
-
| Path safety | MCP / dashboard reject traversal, encoded escapes, hostile URLs |
|
|
337
|
-
| Safe Fix | Preflight targets; refuse symlink write-through / non-allowlisted paths |
|
|
338
|
-
| Secrets | Opt-in scan; findings and exports redact sensitive patterns |
|
|
339
|
-
| Policy | Evaluate-only by default (`executionResult: "not-executed"`) |
|
|
340
|
-
| Enforcement | Controlled runner blocks; does **not** claim IDE interception |
|
|
341
|
-
| Dashboard | Loopback by default; non-loopback requires explicit opt-in |
|
|
342
|
-
| Team auth | Local-dev scrypt + optional OIDC JWT validation — **not** full browser SSO |
|
|
527
|
+
Derived from `package.json` and source:
|
|
343
528
|
|
|
344
|
-
|
|
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 |
|
|
345
541
|
|
|
346
542
|
---
|
|
347
543
|
|
|
348
|
-
##
|
|
544
|
+
## Verification
|
|
545
|
+
|
|
546
|
+
**AgentDoctor 3.0** — local acceptance evidence:
|
|
547
|
+
|
|
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** |
|
|
349
557
|
|
|
350
|
-
|
|
351
|
-
- Complete multi-language AST (Java / Kotlin / Rust / Dart / Go extractors external or unsupported)
|
|
352
|
-
- Coverage as universal ground truth without a coverage file / test map
|
|
353
|
-
- IDE / agent process interception (external host APIs)
|
|
354
|
-
- Production multi-tenant cloud / managed hosting in this package
|
|
355
|
-
- Guaranteed autonomous command execution of “allowed” policies
|
|
356
|
-
- Treating inferred C4 / heuristic impact as approved architecture truth
|
|
357
|
-
- Shipping full `docs/2.0.1/` inside the npm tarball (Option B: README + GitHub docs)
|
|
558
|
+
Reproduce:
|
|
358
559
|
|
|
359
|
-
|
|
560
|
+
```bash
|
|
561
|
+
npm run verify
|
|
562
|
+
```
|
|
360
563
|
|
|
361
564
|
---
|
|
362
565
|
|
|
363
|
-
##
|
|
566
|
+
## Limitations
|
|
364
567
|
|
|
365
|
-
|
|
568
|
+
Honesty is part of the product. Read **[docs/LIMITATIONS.md](docs/LIMITATIONS.md)**.
|
|
366
569
|
|
|
367
|
-
|
|
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).
|
|
368
579
|
|
|
369
580
|
---
|
|
370
581
|
|
|
371
|
-
##
|
|
582
|
+
## Roadmap
|
|
372
583
|
|
|
373
|
-
|
|
|
374
|
-
|
|
|
375
|
-
|
|
|
376
|
-
|
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
584
|
+
| Track | Meaning |
|
|
585
|
+
| -------------------- | --------------------------------------------------------------------------------- |
|
|
586
|
+
| **3.0.0 (released)** | Project intelligence, doctors, twin, what-if, forensic, eval, student/agent loops |
|
|
587
|
+
| **Coming soon** | Maturity, language depth, runtime adapters, DX — not promised ship dates |
|
|
588
|
+
|
|
589
|
+
---
|
|
590
|
+
|
|
591
|
+
## Documentation
|
|
592
|
+
|
|
593
|
+
Full index: **[docs/README.md](docs/README.md)**
|
|
594
|
+
|
|
595
|
+
| Topic | Link |
|
|
596
|
+
| ---------------- | --------------------------------------------------------------------- |
|
|
597
|
+
| Product | [docs/PRODUCT.md](docs/PRODUCT.md) |
|
|
598
|
+
| Project Chat | [docs/PROJECT_CHAT.md](docs/PROJECT_CHAT.md) |
|
|
599
|
+
| AI Agent | [docs/AI_AGENT.md](docs/AI_AGENT.md) |
|
|
600
|
+
| Student mode | [docs/STUDENT_MODE.md](docs/STUDENT_MODE.md) |
|
|
601
|
+
| MCP | [docs/MCP.md](docs/MCP.md) |
|
|
602
|
+
| Approvals | [docs/AGENT_APPROVALS.md](docs/AGENT_APPROVALS.md) |
|
|
603
|
+
| Security model | [docs/SECURITY_MODEL.md](docs/SECURITY_MODEL.md) |
|
|
604
|
+
| Evidence / Proof | [docs/EVIDENCE.md](docs/EVIDENCE.md) · [docs/PROOF.md](docs/PROOF.md) |
|
|
605
|
+
| Project Brain | [docs/PROJECT_BRAIN.md](docs/PROJECT_BRAIN.md) |
|
|
606
|
+
| Limitations | [docs/LIMITATIONS.md](docs/LIMITATIONS.md) |
|
|
607
|
+
| Feature guides | [docs/guides/features/](docs/guides/features/) |
|
|
608
|
+
| Contributing | [CONTRIBUTING.md](CONTRIBUTING.md) |
|
|
609
|
+
| Security policy | [SECURITY.md](SECURITY.md) |
|
|
610
|
+
| Code of conduct | [CODE_OF_CONDUCT.md](CODE_OF_CONDUCT.md) |
|
|
611
|
+
| Changelog | [CHANGELOG.md](CHANGELOG.md) |
|
|
383
612
|
|
|
384
613
|
---
|
|
385
614
|
|
|
386
615
|
## Contributing
|
|
387
616
|
|
|
388
|
-
|
|
617
|
+
```bash
|
|
618
|
+
git clone https://github.com/pranee54/AgentDoctor.git
|
|
619
|
+
cd AgentDoctor
|
|
620
|
+
npm install
|
|
621
|
+
npm run verify
|
|
622
|
+
```
|
|
623
|
+
|
|
624
|
+
See [CONTRIBUTING.md](CONTRIBUTING.md). Issues and PRs welcome via GitHub templates.
|
|
389
625
|
|
|
390
626
|
---
|
|
391
627
|
|
|
392
628
|
## License
|
|
393
629
|
|
|
394
|
-
MIT
|
|
630
|
+
[MIT](LICENSE) © AgentDoctor Contributors
|
|
631
|
+
|
|
632
|
+
---
|
|
633
|
+
|
|
634
|
+
## GitHub discoverability (maintainers)
|
|
635
|
+
|
|
636
|
+
Suggested repository description:
|
|
637
|
+
|
|
638
|
+
> Project intelligence and assurance for software — understand, ask, plan, approve, change, test, secure, verify, and prove. Local-first. MCP-ready.
|
|
639
|
+
|
|
640
|
+
Suggested topics: `software-engineering`, `developer-tools`, `code-intelligence`, `ai-agents`, `mcp`, `static-analysis`, `developer-experience`, `security`, `testing`, `typescript`
|
|
641
|
+
|
|
642
|
+
---
|
|
643
|
+
|
|
644
|
+
**Try it on a real project in five minutes.** If something is UNKNOWN, that is intentional — AgentDoctor should show the boundary, not invent certainty.
|