@organon-methodology/tools 0.3.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.
Files changed (287) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +152 -0
  3. package/dist/cli/commands/coverage.d.ts +12 -0
  4. package/dist/cli/commands/coverage.d.ts.map +1 -0
  5. package/dist/cli/commands/coverage.js +80 -0
  6. package/dist/cli/commands/coverage.js.map +1 -0
  7. package/dist/cli/commands/find.d.ts +15 -0
  8. package/dist/cli/commands/find.d.ts.map +1 -0
  9. package/dist/cli/commands/find.js +81 -0
  10. package/dist/cli/commands/find.js.map +1 -0
  11. package/dist/cli/commands/generate-tests.d.ts +14 -0
  12. package/dist/cli/commands/generate-tests.d.ts.map +1 -0
  13. package/dist/cli/commands/generate-tests.js +87 -0
  14. package/dist/cli/commands/generate-tests.js.map +1 -0
  15. package/dist/cli/commands/generate.d.ts +15 -0
  16. package/dist/cli/commands/generate.d.ts.map +1 -0
  17. package/dist/cli/commands/generate.js +77 -0
  18. package/dist/cli/commands/generate.js.map +1 -0
  19. package/dist/cli/commands/health.d.ts +13 -0
  20. package/dist/cli/commands/health.d.ts.map +1 -0
  21. package/dist/cli/commands/health.js +79 -0
  22. package/dist/cli/commands/health.js.map +1 -0
  23. package/dist/cli/commands/init.d.ts +14 -0
  24. package/dist/cli/commands/init.d.ts.map +1 -0
  25. package/dist/cli/commands/init.js +132 -0
  26. package/dist/cli/commands/init.js.map +1 -0
  27. package/dist/cli/commands/mcp.d.ts +11 -0
  28. package/dist/cli/commands/mcp.d.ts.map +1 -0
  29. package/dist/cli/commands/mcp.js +26 -0
  30. package/dist/cli/commands/mcp.js.map +1 -0
  31. package/dist/cli/commands/query.d.ts +19 -0
  32. package/dist/cli/commands/query.d.ts.map +1 -0
  33. package/dist/cli/commands/query.js +103 -0
  34. package/dist/cli/commands/query.js.map +1 -0
  35. package/dist/cli/commands/upgrade.d.ts +13 -0
  36. package/dist/cli/commands/upgrade.d.ts.map +1 -0
  37. package/dist/cli/commands/upgrade.js +162 -0
  38. package/dist/cli/commands/upgrade.js.map +1 -0
  39. package/dist/cli/commands/validate.d.ts +13 -0
  40. package/dist/cli/commands/validate.d.ts.map +1 -0
  41. package/dist/cli/commands/validate.js +89 -0
  42. package/dist/cli/commands/validate.js.map +1 -0
  43. package/dist/cli/commands/verify.d.ts +12 -0
  44. package/dist/cli/commands/verify.d.ts.map +1 -0
  45. package/dist/cli/commands/verify.js +67 -0
  46. package/dist/cli/commands/verify.js.map +1 -0
  47. package/dist/cli/index.d.ts +19 -0
  48. package/dist/cli/index.d.ts.map +1 -0
  49. package/dist/cli/index.js +59 -0
  50. package/dist/cli/index.js.map +1 -0
  51. package/dist/core/add-protocols-array.d.ts +17 -0
  52. package/dist/core/add-protocols-array.d.ts.map +1 -0
  53. package/dist/core/add-protocols-array.js +95 -0
  54. package/dist/core/add-protocols-array.js.map +1 -0
  55. package/dist/core/add-protocols-array.test.d.ts +2 -0
  56. package/dist/core/add-protocols-array.test.d.ts.map +1 -0
  57. package/dist/core/add-protocols-array.test.js +86 -0
  58. package/dist/core/add-protocols-array.test.js.map +1 -0
  59. package/dist/core/config.d.ts +44 -0
  60. package/dist/core/config.d.ts.map +1 -0
  61. package/dist/core/config.js +130 -0
  62. package/dist/core/config.js.map +1 -0
  63. package/dist/core/config.test.d.ts +2 -0
  64. package/dist/core/config.test.d.ts.map +1 -0
  65. package/dist/core/config.test.js +88 -0
  66. package/dist/core/config.test.js.map +1 -0
  67. package/dist/core/find.d.ts +29 -0
  68. package/dist/core/find.d.ts.map +1 -0
  69. package/dist/core/find.js +191 -0
  70. package/dist/core/find.js.map +1 -0
  71. package/dist/core/find.test.d.ts +2 -0
  72. package/dist/core/find.test.d.ts.map +1 -0
  73. package/dist/core/find.test.js +91 -0
  74. package/dist/core/find.test.js.map +1 -0
  75. package/dist/core/frontmatter-parser.d.ts +45 -0
  76. package/dist/core/frontmatter-parser.d.ts.map +1 -0
  77. package/dist/core/frontmatter-parser.js +122 -0
  78. package/dist/core/frontmatter-parser.js.map +1 -0
  79. package/dist/core/frontmatter-parser.test.d.ts +2 -0
  80. package/dist/core/frontmatter-parser.test.d.ts.map +1 -0
  81. package/dist/core/frontmatter-parser.test.js +200 -0
  82. package/dist/core/frontmatter-parser.test.js.map +1 -0
  83. package/dist/core/generate-frontmatter.d.ts +27 -0
  84. package/dist/core/generate-frontmatter.d.ts.map +1 -0
  85. package/dist/core/generate-frontmatter.js +219 -0
  86. package/dist/core/generate-frontmatter.js.map +1 -0
  87. package/dist/core/generate-frontmatter.test.d.ts +2 -0
  88. package/dist/core/generate-frontmatter.test.d.ts.map +1 -0
  89. package/dist/core/generate-frontmatter.test.js +161 -0
  90. package/dist/core/generate-frontmatter.test.js.map +1 -0
  91. package/dist/core/generate-tests.d.ts +41 -0
  92. package/dist/core/generate-tests.d.ts.map +1 -0
  93. package/dist/core/generate-tests.js +191 -0
  94. package/dist/core/generate-tests.js.map +1 -0
  95. package/dist/core/generate-tests.test.d.ts +2 -0
  96. package/dist/core/generate-tests.test.d.ts.map +1 -0
  97. package/dist/core/generate-tests.test.js +205 -0
  98. package/dist/core/generate-tests.test.js.map +1 -0
  99. package/dist/core/health.d.ts +16 -0
  100. package/dist/core/health.d.ts.map +1 -0
  101. package/dist/core/health.js +156 -0
  102. package/dist/core/health.js.map +1 -0
  103. package/dist/core/health.test.d.ts +2 -0
  104. package/dist/core/health.test.d.ts.map +1 -0
  105. package/dist/core/health.test.js +97 -0
  106. package/dist/core/health.test.js.map +1 -0
  107. package/dist/core/init.d.ts +25 -0
  108. package/dist/core/init.d.ts.map +1 -0
  109. package/dist/core/init.js +100 -0
  110. package/dist/core/init.js.map +1 -0
  111. package/dist/core/init.test.d.ts +8 -0
  112. package/dist/core/init.test.d.ts.map +1 -0
  113. package/dist/core/init.test.js +203 -0
  114. package/dist/core/init.test.js.map +1 -0
  115. package/dist/core/invariant-coverage.d.ts +41 -0
  116. package/dist/core/invariant-coverage.d.ts.map +1 -0
  117. package/dist/core/invariant-coverage.js +181 -0
  118. package/dist/core/invariant-coverage.js.map +1 -0
  119. package/dist/core/invariant-coverage.test.d.ts +2 -0
  120. package/dist/core/invariant-coverage.test.d.ts.map +1 -0
  121. package/dist/core/invariant-coverage.test.js +188 -0
  122. package/dist/core/invariant-coverage.test.js.map +1 -0
  123. package/dist/core/meta-invariants.test.d.ts +17 -0
  124. package/dist/core/meta-invariants.test.d.ts.map +1 -0
  125. package/dist/core/meta-invariants.test.js +191 -0
  126. package/dist/core/meta-invariants.test.js.map +1 -0
  127. package/dist/core/node-fs.d.ts +22 -0
  128. package/dist/core/node-fs.d.ts.map +1 -0
  129. package/dist/core/node-fs.js +47 -0
  130. package/dist/core/node-fs.js.map +1 -0
  131. package/dist/core/organon-invariants.test.d.ts +15 -0
  132. package/dist/core/organon-invariants.test.d.ts.map +1 -0
  133. package/dist/core/organon-invariants.test.js +149 -0
  134. package/dist/core/organon-invariants.test.js.map +1 -0
  135. package/dist/core/query.d.ts +35 -0
  136. package/dist/core/query.d.ts.map +1 -0
  137. package/dist/core/query.js +139 -0
  138. package/dist/core/query.js.map +1 -0
  139. package/dist/core/query.test.d.ts +2 -0
  140. package/dist/core/query.test.d.ts.map +1 -0
  141. package/dist/core/query.test.js +97 -0
  142. package/dist/core/query.test.js.map +1 -0
  143. package/dist/core/suggest-tools.d.ts +15 -0
  144. package/dist/core/suggest-tools.d.ts.map +1 -0
  145. package/dist/core/suggest-tools.js +139 -0
  146. package/dist/core/suggest-tools.js.map +1 -0
  147. package/dist/core/suggest-tools.test.d.ts +2 -0
  148. package/dist/core/suggest-tools.test.d.ts.map +1 -0
  149. package/dist/core/suggest-tools.test.js +122 -0
  150. package/dist/core/suggest-tools.test.js.map +1 -0
  151. package/dist/core/test-helpers.d.ts +63 -0
  152. package/dist/core/test-helpers.d.ts.map +1 -0
  153. package/dist/core/test-helpers.js +265 -0
  154. package/dist/core/test-helpers.js.map +1 -0
  155. package/dist/core/types.d.ts +277 -0
  156. package/dist/core/types.d.ts.map +1 -0
  157. package/dist/core/types.js +9 -0
  158. package/dist/core/types.js.map +1 -0
  159. package/dist/core/upgrade.d.ts +46 -0
  160. package/dist/core/upgrade.d.ts.map +1 -0
  161. package/dist/core/upgrade.js +227 -0
  162. package/dist/core/upgrade.js.map +1 -0
  163. package/dist/core/upgrade.test.d.ts +8 -0
  164. package/dist/core/upgrade.test.d.ts.map +1 -0
  165. package/dist/core/upgrade.test.js +370 -0
  166. package/dist/core/upgrade.test.js.map +1 -0
  167. package/dist/core/validate-frontmatter.d.ts +20 -0
  168. package/dist/core/validate-frontmatter.d.ts.map +1 -0
  169. package/dist/core/validate-frontmatter.js +529 -0
  170. package/dist/core/validate-frontmatter.js.map +1 -0
  171. package/dist/core/validate-frontmatter.test.d.ts +2 -0
  172. package/dist/core/validate-frontmatter.test.d.ts.map +1 -0
  173. package/dist/core/validate-frontmatter.test.js +366 -0
  174. package/dist/core/validate-frontmatter.test.js.map +1 -0
  175. package/dist/core/validate-workflow.d.ts +17 -0
  176. package/dist/core/validate-workflow.d.ts.map +1 -0
  177. package/dist/core/validate-workflow.js +233 -0
  178. package/dist/core/validate-workflow.js.map +1 -0
  179. package/dist/core/validate-workflow.test.d.ts +2 -0
  180. package/dist/core/validate-workflow.test.d.ts.map +1 -0
  181. package/dist/core/validate-workflow.test.js +205 -0
  182. package/dist/core/validate-workflow.test.js.map +1 -0
  183. package/dist/core/verify-tier4-tests.d.ts +34 -0
  184. package/dist/core/verify-tier4-tests.d.ts.map +1 -0
  185. package/dist/core/verify-tier4-tests.js +106 -0
  186. package/dist/core/verify-tier4-tests.js.map +1 -0
  187. package/dist/core/verify-tier4-tests.test.d.ts +2 -0
  188. package/dist/core/verify-tier4-tests.test.d.ts.map +1 -0
  189. package/dist/core/verify-tier4-tests.test.js +140 -0
  190. package/dist/core/verify-tier4-tests.test.js.map +1 -0
  191. package/dist/core/verify-triplets.d.ts +17 -0
  192. package/dist/core/verify-triplets.d.ts.map +1 -0
  193. package/dist/core/verify-triplets.js +217 -0
  194. package/dist/core/verify-triplets.js.map +1 -0
  195. package/dist/core/verify-triplets.test.d.ts +2 -0
  196. package/dist/core/verify-triplets.test.d.ts.map +1 -0
  197. package/dist/core/verify-triplets.test.js +147 -0
  198. package/dist/core/verify-triplets.test.js.map +1 -0
  199. package/dist/core/verify.d.ts +19 -0
  200. package/dist/core/verify.d.ts.map +1 -0
  201. package/dist/core/verify.js +162 -0
  202. package/dist/core/verify.js.map +1 -0
  203. package/dist/core/verify.test.d.ts +2 -0
  204. package/dist/core/verify.test.d.ts.map +1 -0
  205. package/dist/core/verify.test.js +147 -0
  206. package/dist/core/verify.test.js.map +1 -0
  207. package/dist/index.d.ts +31 -0
  208. package/dist/index.d.ts.map +1 -0
  209. package/dist/index.js +27 -0
  210. package/dist/index.js.map +1 -0
  211. package/dist/mcp/prompts.d.ts +9 -0
  212. package/dist/mcp/prompts.d.ts.map +1 -0
  213. package/dist/mcp/prompts.js +265 -0
  214. package/dist/mcp/prompts.js.map +1 -0
  215. package/dist/mcp/resources.d.ts +7 -0
  216. package/dist/mcp/resources.d.ts.map +1 -0
  217. package/dist/mcp/resources.js +111 -0
  218. package/dist/mcp/resources.js.map +1 -0
  219. package/dist/mcp/server.d.ts +7 -0
  220. package/dist/mcp/server.d.ts.map +1 -0
  221. package/dist/mcp/server.js +31 -0
  222. package/dist/mcp/server.js.map +1 -0
  223. package/dist/mcp/tools.d.ts +7 -0
  224. package/dist/mcp/tools.d.ts.map +1 -0
  225. package/dist/mcp/tools.js +130 -0
  226. package/dist/mcp/tools.js.map +1 -0
  227. package/dist/templates/config.d.ts +6 -0
  228. package/dist/templates/config.d.ts.map +1 -0
  229. package/dist/templates/config.js +30 -0
  230. package/dist/templates/config.js.map +1 -0
  231. package/dist/templates/index.d.ts +7 -0
  232. package/dist/templates/index.d.ts.map +1 -0
  233. package/dist/templates/index.js +7 -0
  234. package/dist/templates/index.js.map +1 -0
  235. package/dist/templates/organon/claude-md.d.ts +7 -0
  236. package/dist/templates/organon/claude-md.d.ts.map +1 -0
  237. package/dist/templates/organon/claude-md.js +32 -0
  238. package/dist/templates/organon/claude-md.js.map +1 -0
  239. package/dist/templates/organon/ethos.d.ts +5 -0
  240. package/dist/templates/organon/ethos.d.ts.map +1 -0
  241. package/dist/templates/organon/ethos.js +69 -0
  242. package/dist/templates/organon/ethos.js.map +1 -0
  243. package/dist/templates/organon/index.d.ts +10 -0
  244. package/dist/templates/organon/index.d.ts.map +1 -0
  245. package/dist/templates/organon/index.js +10 -0
  246. package/dist/templates/organon/index.js.map +1 -0
  247. package/dist/templates/organon/observations-readme.d.ts +5 -0
  248. package/dist/templates/organon/observations-readme.d.ts.map +1 -0
  249. package/dist/templates/organon/observations-readme.js +25 -0
  250. package/dist/templates/organon/observations-readme.js.map +1 -0
  251. package/dist/templates/organon/philosophy.d.ts +5 -0
  252. package/dist/templates/organon/philosophy.d.ts.map +1 -0
  253. package/dist/templates/organon/philosophy.js +75 -0
  254. package/dist/templates/organon/philosophy.js.map +1 -0
  255. package/dist/templates/organon/protocols.d.ts +7 -0
  256. package/dist/templates/organon/protocols.d.ts.map +1 -0
  257. package/dist/templates/organon/protocols.js +197 -0
  258. package/dist/templates/organon/protocols.js.map +1 -0
  259. package/dist/templates/organon/readme.d.ts +5 -0
  260. package/dist/templates/organon/readme.d.ts.map +1 -0
  261. package/dist/templates/organon/readme.js +40 -0
  262. package/dist/templates/organon/readme.js.map +1 -0
  263. package/dist/templates/skills/domain-feature-design.d.ts +9 -0
  264. package/dist/templates/skills/domain-feature-design.d.ts.map +1 -0
  265. package/dist/templates/skills/domain-feature-design.js +123 -0
  266. package/dist/templates/skills/domain-feature-design.js.map +1 -0
  267. package/dist/templates/skills/index.d.ts +15 -0
  268. package/dist/templates/skills/index.d.ts.map +1 -0
  269. package/dist/templates/skills/index.js +35 -0
  270. package/dist/templates/skills/index.js.map +1 -0
  271. package/dist/templates/skills/organon-file-creation.d.ts +9 -0
  272. package/dist/templates/skills/organon-file-creation.d.ts.map +1 -0
  273. package/dist/templates/skills/organon-file-creation.js +138 -0
  274. package/dist/templates/skills/organon-file-creation.js.map +1 -0
  275. package/dist/templates/skills/quality-review.d.ts +9 -0
  276. package/dist/templates/skills/quality-review.d.ts.map +1 -0
  277. package/dist/templates/skills/quality-review.js +127 -0
  278. package/dist/templates/skills/quality-review.js.map +1 -0
  279. package/dist/templates/skills/session-compounding.d.ts +9 -0
  280. package/dist/templates/skills/session-compounding.d.ts.map +1 -0
  281. package/dist/templates/skills/session-compounding.js +118 -0
  282. package/dist/templates/skills/session-compounding.js.map +1 -0
  283. package/dist/templates/skills/verify-and-health.d.ts +9 -0
  284. package/dist/templates/skills/verify-and-health.d.ts.map +1 -0
  285. package/dist/templates/skills/verify-and-health.js +99 -0
  286. package/dist/templates/skills/verify-and-health.js.map +1 -0
  287. package/package.json +72 -0
@@ -0,0 +1,147 @@
1
+ import { describe, it, expect } from 'vitest';
2
+ import { verify, registerGate, getRegisteredGates } from './verify.js';
3
+ import { MemoryFileSystem, makeEthos } from './test-helpers.js';
4
+ function makeConfig(projectRoot) {
5
+ return {
6
+ projectRoot,
7
+ organonPaths: ['.'],
8
+ organonGlobs: ['**/ETHOS.md'],
9
+ ignorePatterns: [],
10
+ workflowPaths: {},
11
+ freshnessThresholdHours: 24,
12
+ };
13
+ }
14
+ describe('verify', () => {
15
+ it('runs all built-in gates', async () => {
16
+ const fs = new MemoryFileSystem({
17
+ '/project/ETHOS.md': makeEthos({ name: 'test', scope: 'product' }),
18
+ });
19
+ const config = makeConfig('/project');
20
+ const result = await verify({ projectRoot: '/project', config, fs });
21
+ // Should have at least the 4 built-in gates
22
+ expect(result.gates.length).toBeGreaterThanOrEqual(4);
23
+ const gateNames = result.gates.map((g) => g.gate);
24
+ expect(gateNames).toContain('frontmatter');
25
+ expect(gateNames).toContain('triplets');
26
+ expect(gateNames).toContain('freshness');
27
+ expect(gateNames).toContain('invariant-coverage');
28
+ });
29
+ it('runs a specific gate subset', async () => {
30
+ const fs = new MemoryFileSystem({
31
+ '/project/ETHOS.md': makeEthos({ name: 'test', scope: 'product' }),
32
+ });
33
+ const config = makeConfig('/project');
34
+ const result = await verify({
35
+ projectRoot: '/project',
36
+ config,
37
+ fs,
38
+ gates: ['frontmatter'],
39
+ });
40
+ expect(result.gates.length).toBe(1);
41
+ expect(result.gates[0].gate).toBe('frontmatter');
42
+ });
43
+ it('reports error for unknown gate', async () => {
44
+ const fs = new MemoryFileSystem({
45
+ '/project/ETHOS.md': makeEthos({ name: 'test', scope: 'product' }),
46
+ });
47
+ const config = makeConfig('/project');
48
+ const result = await verify({
49
+ projectRoot: '/project',
50
+ config,
51
+ fs,
52
+ gates: ['nonexistent-gate'],
53
+ });
54
+ expect(result.errors).toContainEqual(expect.objectContaining({ code: 'UNKNOWN_GATE' }));
55
+ });
56
+ it('supports custom gate registration', async () => {
57
+ const customGate = async () => ({
58
+ gate: 'custom',
59
+ passed: true,
60
+ errors: [],
61
+ warnings: [],
62
+ });
63
+ registerGate('custom-test', customGate);
64
+ expect(getRegisteredGates()).toContain('custom-test');
65
+ const fs = new MemoryFileSystem({
66
+ '/project/ETHOS.md': makeEthos({ name: 'test', scope: 'product' }),
67
+ });
68
+ const config = makeConfig('/project');
69
+ const result = await verify({
70
+ projectRoot: '/project',
71
+ config,
72
+ fs,
73
+ gates: ['custom-test'],
74
+ });
75
+ expect(result.gates.length).toBe(1);
76
+ expect(result.gates[0].gate).toBe('custom');
77
+ expect(result.gates[0].passed).toBe(true);
78
+ });
79
+ it('handles gate execution errors gracefully', async () => {
80
+ const failingGate = async () => {
81
+ throw new Error('Gate crashed');
82
+ };
83
+ registerGate('failing-test', failingGate);
84
+ const fs = new MemoryFileSystem({
85
+ '/project/ETHOS.md': makeEthos({ name: 'test', scope: 'product' }),
86
+ });
87
+ const config = makeConfig('/project');
88
+ const result = await verify({
89
+ projectRoot: '/project',
90
+ config,
91
+ fs,
92
+ gates: ['failing-test'],
93
+ });
94
+ expect(result.success).toBe(false);
95
+ expect(result.errors).toContainEqual(expect.objectContaining({ code: 'GATE_EXECUTION_ERROR' }));
96
+ });
97
+ it('invariant-coverage gate passes when no invariants defined', async () => {
98
+ const fs = new MemoryFileSystem({
99
+ '/project/ETHOS.md': makeEthos({ name: 'test', scope: 'product' }),
100
+ });
101
+ const config = makeConfig('/project');
102
+ const result = await verify({
103
+ projectRoot: '/project',
104
+ config,
105
+ fs,
106
+ gates: ['invariant-coverage'],
107
+ });
108
+ expect(result.gates[0].gate).toBe('invariant-coverage');
109
+ expect(result.gates[0].passed).toBe(true);
110
+ });
111
+ it('invariant-coverage gate fails when invariants are uncovered', async () => {
112
+ const ethosContent = makeEthos({
113
+ name: 'test',
114
+ scope: 'product',
115
+ extra: {
116
+ invariants: `\n - id: INV-TEST-1\n name: rule-one`,
117
+ },
118
+ });
119
+ const fs = new MemoryFileSystem({
120
+ '/project/ETHOS.md': ethosContent,
121
+ });
122
+ const config = makeConfig('/project');
123
+ const result = await verify({
124
+ projectRoot: '/project',
125
+ config,
126
+ fs,
127
+ gates: ['invariant-coverage'],
128
+ });
129
+ expect(result.gates[0].gate).toBe('invariant-coverage');
130
+ expect(result.gates[0].passed).toBe(false);
131
+ });
132
+ it('success is true only when all gates pass', async () => {
133
+ const fs = new MemoryFileSystem({
134
+ '/project/ETHOS.md': makeEthos({ name: 'test', scope: 'product' }),
135
+ });
136
+ const config = makeConfig('/project');
137
+ // Frontmatter should pass on a valid file, triplets pass (no protocols), freshness is advisory
138
+ const result = await verify({
139
+ projectRoot: '/project',
140
+ config,
141
+ fs,
142
+ gates: ['frontmatter', 'triplets'],
143
+ });
144
+ expect(result.success).toBe(true);
145
+ });
146
+ });
147
+ //# sourceMappingURL=verify.test.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"verify.test.js","sourceRoot":"","sources":["../../src/core/verify.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,MA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MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACpC,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Public API for programmatic use of Organon tools.
3
+ *
4
+ * Import from '@organon-methodology/tools' or '@organon-methodology/tools/core/*'.
5
+ */
6
+ export type { FileSystem, FileStat, DiagnosticMessage, Severity, Frontmatter, FrontmatterType, FrontmatterScope, AutomationTier, LoadPriority, Complexity, Audience, ProtocolEntry, InvariantEntry, ParsedOrganonFile, OrganonConfig, WorkflowPaths, ValidateFrontmatterResult, FileValidationResult, GenerateFrontmatterResult, QueryResult, HealthResult, FindResult, FindMatch, VerifyTripletsResult, TripletBinding, WorkflowValidationResult, WorkflowFileResult, SuggestToolsResult, ToolSuggestion, VerifyResult, VerifyGateResult, VerifyGateFn, InvariantCoverageResult, InvariantCoverageEntry, } from './core/types.js';
7
+ export { resolveConfig, joinPath, dirName, baseName } from './core/config.js';
8
+ export type { ConfigFile } from './core/config.js';
9
+ export { NodeFileSystem, resolvePath } from './core/node-fs.js';
10
+ export { parseFrontmatter, parseOrganonFile, estimateTokens, countSectionEntries, extractSection, countTableRows, } from './core/frontmatter-parser.js';
11
+ export { validateFrontmatter } from './core/validate-frontmatter.js';
12
+ export type { ValidateFrontmatterOptions } from './core/validate-frontmatter.js';
13
+ export { generateFrontmatter, serializeFrontmatter } from './core/generate-frontmatter.js';
14
+ export type { GenerateFrontmatterOptions } from './core/generate-frontmatter.js';
15
+ export { query } from './core/query.js';
16
+ export type { QueryOptions } from './core/query.js';
17
+ export { health } from './core/health.js';
18
+ export type { HealthOptions } from './core/health.js';
19
+ export { find } from './core/find.js';
20
+ export type { FindOptions } from './core/find.js';
21
+ export { verifyTriplets } from './core/verify-triplets.js';
22
+ export type { VerifyTripletsOptions } from './core/verify-triplets.js';
23
+ export { suggestTools } from './core/suggest-tools.js';
24
+ export type { SuggestToolsOptions } from './core/suggest-tools.js';
25
+ export { verify, registerGate, getRegisteredGates } from './core/verify.js';
26
+ export type { VerifyOptions } from './core/verify.js';
27
+ export { computeInvariantCoverage, extractInvariants, scanTestAnnotations, computeCoverage } from './core/invariant-coverage.js';
28
+ export { validateWorkflow } from './core/validate-workflow.js';
29
+ export type { ValidateWorkflowOptions } from './core/validate-workflow.js';
30
+ export { parseProtocols } from './core/add-protocols-array.js';
31
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAGH,YAAY,EACV,UAAU,EACV,QAAQ,EACR,iBAAiB,EACjB,QAAQ,EACR,WAAW,EACX,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,YAAY,EACZ,UAAU,EACV,QAAQ,EACR,aAAa,EACb,cAAc,EACd,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,yBAAyB,EACzB,oBAAoB,EACpB,yBAAyB,EACzB,WAAW,EACX,YAAY,EACZ,UAAU,EACV,SAAS,EACT,oBAAoB,EACpB,cAAc,EACd,wBAAwB,EACxB,kBAAkB,EAClB,kBAAkB,EAClB,cAAc,EACd,YAAY,EACZ,gBAAgB,EAChB,YAAY,EACZ,uBAAuB,EACvB,sBAAsB,GACvB,MAAM,iBAAiB,CAAC;AAGzB,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC9E,YAAY,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAGnD,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAGhE,OAAO,EACL,gBAAgB,EAChB,gBAAgB,EAChB,cAAc,EACd,mBAAmB,EACnB,cAAc,EACd,cAAc,GACf,MAAM,8BAA8B,CAAC;AAGtC,OAAO,EAAE,mBAAmB,EAAE,MAAM,gCAAgC,CAAC;AACrE,YAAY,EAAE,0BAA0B,EAAE,MAAM,gCAAgC,CAAC;AAEjF,OAAO,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AAC3F,YAAY,EAAE,0BAA0B,EAAE,MAAM,gCAAgC,CAAC;AAEjF,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AACxC,YAAY,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAEpD,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAC1C,YAAY,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAEtD,OAAO,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AACtC,YAAY,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAElD,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,YAAY,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAEvE,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACvD,YAAY,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAEnE,OAAO,EAAE,MAAM,EAAE,YAAY,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAC5E,YAAY,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAGtD,OAAO,EAAE,wBAAwB,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAGjI,OAAO,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAC/D,YAAY,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC;AAG3E,OAAO,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Public API for programmatic use of Organon tools.
3
+ *
4
+ * Import from '@organon-methodology/tools' or '@organon-methodology/tools/core/*'.
5
+ */
6
+ // Config
7
+ export { resolveConfig, joinPath, dirName, baseName } from './core/config.js';
8
+ // FileSystem implementation
9
+ export { NodeFileSystem, resolvePath } from './core/node-fs.js';
10
+ // Frontmatter parser
11
+ export { parseFrontmatter, parseOrganonFile, estimateTokens, countSectionEntries, extractSection, countTableRows, } from './core/frontmatter-parser.js';
12
+ // Core functions
13
+ export { validateFrontmatter } from './core/validate-frontmatter.js';
14
+ export { generateFrontmatter, serializeFrontmatter } from './core/generate-frontmatter.js';
15
+ export { query } from './core/query.js';
16
+ export { health } from './core/health.js';
17
+ export { find } from './core/find.js';
18
+ export { verifyTriplets } from './core/verify-triplets.js';
19
+ export { suggestTools } from './core/suggest-tools.js';
20
+ export { verify, registerGate, getRegisteredGates } from './core/verify.js';
21
+ // Invariant coverage
22
+ export { computeInvariantCoverage, extractInvariants, scanTestAnnotations, computeCoverage } from './core/invariant-coverage.js';
23
+ // Workflow validation
24
+ export { validateWorkflow } from './core/validate-workflow.js';
25
+ // Protocol parsing
26
+ export { parseProtocols } from './core/add-protocols-array.js';
27
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAwCH,SAAS;AACT,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAG9E,4BAA4B;AAC5B,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAEhE,qBAAqB;AACrB,OAAO,EACL,gBAAgB,EAChB,gBAAgB,EAChB,cAAc,EACd,mBAAmB,EACnB,cAAc,EACd,cAAc,GACf,MAAM,8BAA8B,CAAC;AAEtC,iBAAiB;AACjB,OAAO,EAAE,mBAAmB,EAAE,MAAM,gCAAgC,CAAC;AAGrE,OAAO,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AAG3F,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAGxC,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAG1C,OAAO,EAAE,IAAI,EAAE,MAAM,gBAAgB,CAAC;AAGtC,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAG3D,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAGvD,OAAO,EAAE,MAAM,EAAE,YAAY,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAG5E,qBAAqB;AACrB,OAAO,EAAE,wBAAwB,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAEjI,sBAAsB;AACtB,OAAO,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAG/D,mBAAmB;AACnB,OAAO,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * MCP Prompt registrations — 4 methodology workflow prompts.
3
+ *
4
+ * These encode the Organon methodology workflows so fresh agents
5
+ * can follow correct procedures without prior context.
6
+ */
7
+ import type { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
8
+ export declare function registerPrompts(server: McpServer): void;
9
+ //# sourceMappingURL=prompts.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"prompts.d.ts","sourceRoot":"","sources":["../../src/mcp/prompts.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEzE,wBAAgB,eAAe,CAAC,MAAM,EAAE,SAAS,GAAG,IAAI,CA0RvD"}
@@ -0,0 +1,265 @@
1
+ /**
2
+ * MCP Prompt registrations — 4 methodology workflow prompts.
3
+ *
4
+ * These encode the Organon methodology workflows so fresh agents
5
+ * can follow correct procedures without prior context.
6
+ */
7
+ import { z } from 'zod';
8
+ export function registerPrompts(server) {
9
+ // 1. implement-feature — Ethos-first feature development
10
+ server.prompt('implement-feature', 'Guide through ethos-first feature development: load context, create ETHOS.md, implement, verify', {
11
+ featureName: z.string().describe('Name of the feature to implement'),
12
+ domain: z.string().optional().describe('Target domain (if known)'),
13
+ }, (args) => {
14
+ const domain = args.domain ? `in the **${args.domain}** domain` : '';
15
+ return {
16
+ messages: [{
17
+ role: 'user',
18
+ content: {
19
+ type: 'text',
20
+ text: `# Implement Feature: ${args.featureName}
21
+
22
+ Follow the Organon ethos-first development workflow ${domain}:
23
+
24
+ ## Step 1: Load Context
25
+ 1. Use \`organon_query\` with \`scope: "product"\` to load product-level constraints
26
+ ${args.domain ? `2. Use \`organon_query\` with \`scope: "domain"\` and \`name: "${args.domain}"\` to load domain constraints` : '2. Use `organon_find` to identify which domain this feature belongs to'}
27
+ 3. Use \`organon_query\` with \`task: "${args.featureName.toLowerCase().replace(/\s+/g, '_')}"\` to find relevant organons
28
+ 4. Check token budget — keep organon context under 15K tokens
29
+
30
+ ## Step 2: Create Feature ETHOS.md (if new)
31
+ If this is a new feature, create its ETHOS.md first:
32
+ 1. Create \`organon/features/${args.featureName.toLowerCase().replace(/\s+/g, '-')}/ETHOS.md\`
33
+ 2. Include: Identity (IS/IS NOT), Invariants, Principles (prioritized), Decision Heuristics
34
+ 3. Use \`organon_generate_frontmatter\` to add proper frontmatter
35
+ 4. Use \`organon_validate_frontmatter\` to verify
36
+
37
+ ## Step 3: Implement
38
+ 1. Write code that satisfies the constraints from loaded organons
39
+ 2. Follow the priority order: invariants > principles (lower number wins)
40
+ 3. When uncertain, consult Decision Heuristics tables
41
+
42
+ ## Step 4: Verify
43
+ 1. Use \`organon_verify\` to run all verification gates
44
+ 2. Use \`organon_health\` to check overall system health
45
+ 3. Ensure no new violations were introduced
46
+
47
+ ## Step 5: Update Organons
48
+ 1. If implementation changes any constraints, update the affected ETHOS.md
49
+ 2. Use \`organon_validate_frontmatter\` to verify counts are still accurate
50
+ 3. Organon updates happen in the SAME PR as implementation (never deferred)`,
51
+ },
52
+ }],
53
+ };
54
+ });
55
+ // 2. review-changes — Review against invariants
56
+ server.prompt('review-changes', 'Review code changes against organon constraints: load relevant organons, check invariant violations, run verification', {
57
+ scope: z.string().optional().describe('Limit review to this scope'),
58
+ }, (args) => {
59
+ return {
60
+ messages: [{
61
+ role: 'user',
62
+ content: {
63
+ type: 'text',
64
+ text: `# Review Changes Against Organon Constraints
65
+
66
+ ## Step 1: Identify Affected Organons
67
+ 1. Look at the files changed in this PR/commit
68
+ 2. Use \`organon_find\` with \`--file\` for each changed file to identify governing organons
69
+ 3. Load all identified organons${args.scope ? ` (filtered to scope: ${args.scope})` : ''}
70
+
71
+ ## Step 2: Check Invariant Compliance
72
+ For each governing organon:
73
+ 1. Read the \`## Invariants\` section
74
+ 2. Verify that NONE of the changes violate any invariant
75
+ 3. If an invariant is violated, this is a blocking issue — changes must be revised
76
+
77
+ ## Step 3: Check Principle Alignment
78
+ 1. Read the \`## Principles\` section
79
+ 2. Verify changes align with principles (lower number = higher priority)
80
+ 3. If principles conflict, the lower-numbered principle wins
81
+
82
+ ## Step 4: Run Automated Verification
83
+ 1. Use \`organon_verify\` to run all verification gates
84
+ 2. Report any failures — these must be fixed before merge
85
+
86
+ ## Step 5: Check Organon Freshness
87
+ 1. Use \`organon_health\` to check if any affected organons are stale
88
+ 2. If organon and code have diverged, flag for review
89
+ 3. Ensure frontmatter counts are still accurate
90
+
91
+ ## Review Output Format
92
+ Provide:
93
+ - List of governing organons consulted
94
+ - Invariant compliance: PASS / FAIL (with details)
95
+ - Principle alignment: notes on any tensions
96
+ - Verification gates: all PASS / specific failures
97
+ - Recommendations: any organon updates needed`,
98
+ },
99
+ }],
100
+ };
101
+ });
102
+ // 3. create-organon — Create new organon artifact
103
+ server.prompt('create-organon', 'Guide creation of a new organon artifact with correct structure and frontmatter', {
104
+ artifactType: z.enum(['ethos', 'philosophy', 'protocol']).describe('Type of artifact to create'),
105
+ scope: z.enum(['product', 'domain', 'feature', 'component', 'methodology']).describe('Scope level'),
106
+ name: z.string().describe('Name for the organon (kebab-case)'),
107
+ }, (args) => {
108
+ const structures = {
109
+ ethos: `## Identity
110
+
111
+ ### What ${args.name} IS
112
+ - [Core identity statement]
113
+
114
+ ### What ${args.name} IS NOT
115
+ - [Boundary statement]
116
+
117
+ ## Invariants
118
+
119
+ 1. **[Rule name].** [Rule description.]
120
+
121
+ ## Principles (Prioritized)
122
+
123
+ 1. **[Highest priority].** [Description.]
124
+
125
+ ## Decision Heuristics
126
+
127
+ | Situation | Action |
128
+ |-----------|--------|
129
+ | When [X] | Do [Y] |`,
130
+ philosophy: `## The Problem
131
+
132
+ [Describe the challenge this solves.]
133
+
134
+ ## The Bet
135
+
136
+ [Core approach chosen.]
137
+
138
+ ## Design Decisions
139
+
140
+ ### 1. [Decision Name]
141
+ [What and why.]
142
+ **Rationale:** [Reasoning.]
143
+
144
+ ## Trade-offs
145
+
146
+ | Decision | Benefit | Cost |
147
+ |----------|---------|------|
148
+ | [Choice] | [Gain] | [Sacrifice] |`,
149
+ protocol: `## Goal
150
+
151
+ [What successful completion achieves.]
152
+
153
+ ## Preconditions
154
+
155
+ Before starting, verify:
156
+ - [ ] [Required condition]
157
+
158
+ ## Steps
159
+
160
+ 1. **[Step name].** [Action.]
161
+ 2. **[Step name].** [Action.]
162
+
163
+ ## Verification
164
+
165
+ After completion, confirm:
166
+ - [ ] [Observable outcome]`,
167
+ };
168
+ const typeMap = {
169
+ ethos: 'constraints',
170
+ philosophy: 'rationale',
171
+ protocol: 'procedures',
172
+ };
173
+ return {
174
+ messages: [{
175
+ role: 'user',
176
+ content: {
177
+ type: 'text',
178
+ text: `# Create ${args.artifactType.toUpperCase()}.md for "${args.name}"
179
+
180
+ ## Step 1: Check Parent Scope
181
+ 1. Use \`organon_find\` with \`scope: "product"\` to load product-level constraints
182
+ 2. This new organon must inherit from and never contradict parent constraints
183
+ 3. Add \`inherits_from\` in frontmatter referencing the parent
184
+
185
+ ## Step 2: Create File
186
+ Create \`organon/${args.scope === 'domain' ? 'domains' : args.scope === 'feature' ? 'features' : args.scope + 's'}/${args.name}/${args.artifactType.toUpperCase()}.md\`
187
+
188
+ ## Step 3: Add Frontmatter
189
+ \`\`\`yaml
190
+ ---
191
+ type: ${typeMap[args.artifactType]}
192
+ scope: ${args.scope}
193
+ name: ${args.name}
194
+ version: "1.0"
195
+ summary: [One sentence, max 200 chars]
196
+ token_estimate: [Will be calculated]
197
+ inherits_from: [product]
198
+ ---
199
+ \`\`\`
200
+
201
+ ## Step 4: Add Structure
202
+ Use this template:
203
+
204
+ ${structures[args.artifactType]}
205
+
206
+ ## Step 5: Generate & Validate
207
+ 1. Use \`organon_generate_frontmatter\` to calculate counts and token_estimate
208
+ 2. Use \`organon_validate_frontmatter\` to verify the file passes all 4 stages
209
+ 3. Fix any issues before committing`,
210
+ },
211
+ }],
212
+ };
213
+ });
214
+ // 4. evolve-organon — Modify existing constraints
215
+ server.prompt('evolve-organon', 'Guide organon evolution with RFC-awareness for constraint changes', {
216
+ organonPath: z.string().describe('Path to the organon file to evolve'),
217
+ changeType: z.enum(['add-invariant', 'modify-invariant', 'add-principle', 'update-counts', 'add-heuristic']).describe('Type of change'),
218
+ }, (args) => {
219
+ const needsRfc = ['add-invariant', 'modify-invariant', 'add-principle'].includes(args.changeType);
220
+ return {
221
+ messages: [{
222
+ role: 'user',
223
+ content: {
224
+ type: 'text',
225
+ text: `# Evolve Organon: ${args.organonPath}
226
+ Change type: **${args.changeType}**
227
+
228
+ ${needsRfc ? `## RFC Required
229
+ This change type (${args.changeType}) modifies constraints. Per the RFC-Driven Evolution pattern:
230
+ - **New product-level invariants** require an RFC
231
+ - **Constraint modifications** require an RFC
232
+ - An RFC documents the rationale and impact
233
+
234
+ ### RFC Checklist
235
+ 1. Create an RFC document describing the change and rationale
236
+ 2. Include an "Organon Impact" section listing files to create/update/delete
237
+ 3. Get the RFC reviewed and accepted before proceeding
238
+
239
+ ` : '## Direct Edit Allowed\nThis change type does not require an RFC (it\'s a non-constraint update).\n\n'}## Step 1: Load Current State
240
+ 1. Read the current file at \`${args.organonPath}\`
241
+ 2. Use \`organon_validate_frontmatter\` with the file to check current validity
242
+ 3. Note current counts in frontmatter
243
+
244
+ ## Step 2: Make the Change
245
+ Apply the ${args.changeType} change to the file content.
246
+
247
+ ## Step 3: Update Frontmatter
248
+ 1. Use \`organon_generate_frontmatter\` to recalculate counts and token_estimate
249
+ 2. Bump the version number (minor version for additions, patch for corrections)
250
+ 3. Update \`last_reviewed\` to today's date
251
+
252
+ ## Step 4: Verify
253
+ 1. Use \`organon_validate_frontmatter\` to verify the updated file
254
+ 2. Use \`organon_verify\` to check nothing is broken system-wide
255
+ 3. Check that child organons don't contradict the updated constraints
256
+
257
+ ## Step 5: Same-PR Principle
258
+ Organon updates must be in the SAME commit/PR as any related code changes.
259
+ Never defer organon updates to a follow-up PR.`,
260
+ },
261
+ }],
262
+ };
263
+ });
264
+ }
265
+ //# sourceMappingURL=prompts.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"prompts.js","sourceRoot":"","sources":["../../src/mcp/prompts.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,MAAM,UAAU,eAAe,CAAC,MAAiB;IAC/C,yDAAyD;IACzD,MAAM,CAAC,MAAM,CACX,mBAAmB,EACnB,iGAAiG,EACjG;QACE,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,kCAAkC,CAAC;QACpE,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,0BAA0B,CAAC;KACnE,EACD,CAAC,IAAI,EAAE,EAAE;QACP,MAAM,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,YAAY,IAAI,CAAC,MAAM,WAAW,CAAC,CAAC,CAAC,EAAE,CAAC;QACrE,OAAO;YACL,QAAQ,EAAE,CAAC;oBACT,IAAI,EAAE,MAAM;oBACZ,OAAO,EAAE;wB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M,CACX,gBAAgB,EAChB,mEAAmE,EACnE;QACE,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,oCAAoC,CAAC;QACtE,UAAU,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,eAAe,EAAE,kBAAkB,EAAE,eAAe,EAAE,eAAe,EAAE,eAAe,CAAC,CAAC,CAAC,QAAQ,CAAC,gBAAgB,CAAC;KACxI,EACD,CAAC,IAAI,EAAE,EAAE;QACP,MAAM,QAAQ,GAAG,CAAC,eAAe,EAAE,kBAAkB,EAAE,eAAe,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QAElG,OAAO;YACL,QAAQ,EAAE,CAAC;oBACT,IAAI,EAAE,MAAM;oBACZ,OAAO,EAAE;wBACP,IAAI,EAAE,MAAM;wBACZ,IAAI,EAAE,qBAAqB,IAAI,CAAC,WAAW;iBACtC,IAAI,CAAC,UAAU;;EAE9B,QAAQ,CAAC,CAAC,CAAC;oBACO,IAAI,CAAC,UAAU;;;;;;;;;;CAUlC,CAAC,CAAC,CAAC,uGAAuG;gCAC3E,IAAI,CAAC,WAAW;;;;;YAKpC,IAAI,CAAC,UAAU;;;;;;;;;;;;;;+CAcoB;qBACpC;iBACF,CAAC;SACH,CAAC;IACJ,CAAC,CACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * MCP Resource registrations — 4 resources exposing the organon hierarchy.
3
+ */
4
+ import type { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
5
+ import type { FileSystem, OrganonConfig } from '../core/types.js';
6
+ export declare function registerResources(server: McpServer, projectRoot: string, config: OrganonConfig, fs: FileSystem): void;
7
+ //# sourceMappingURL=resources.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resources.d.ts","sourceRoot":"","sources":["../../src/mcp/resources.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACzE,OAAO,KAAK,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAMlE,wBAAgB,iBAAiB,CAC/B,MAAM,EAAE,SAAS,EACjB,WAAW,EAAE,MAAM,EACnB,MAAM,EAAE,aAAa,EACrB,EAAE,EAAE,UAAU,GACb,IAAI,CAgIN"}
@@ -0,0 +1,111 @@
1
+ /**
2
+ * MCP Resource registrations — 4 resources exposing the organon hierarchy.
3
+ */
4
+ import { query } from '../core/query.js';
5
+ import { health } from '../core/health.js';
6
+ import { joinPath } from '../core/config.js';
7
+ export function registerResources(server, projectRoot, config, fs) {
8
+ // 1. Index — all organon files with frontmatter summaries
9
+ server.resource('organon-index', 'organon://index', async (uri) => {
10
+ const result = await query({
11
+ projectRoot,
12
+ config,
13
+ fs,
14
+ verbose: false,
15
+ });
16
+ const index = result.files.map((f) => ({
17
+ path: f.path,
18
+ type: f.frontmatter?.type,
19
+ scope: f.frontmatter?.scope,
20
+ name: f.frontmatter?.name,
21
+ summary: f.frontmatter?.summary,
22
+ token_estimate: f.frontmatter?.token_estimate,
23
+ load_priority: f.frontmatter?.load_priority,
24
+ }));
25
+ return {
26
+ contents: [{
27
+ uri: uri.href,
28
+ mimeType: 'application/json',
29
+ text: JSON.stringify(index, null, 2),
30
+ }],
31
+ };
32
+ });
33
+ // 2. File — read individual organon file by path
34
+ server.resource('organon-file', 'organon://file/{path}', async (uri) => {
35
+ const filePath = uri.pathname.replace(/^\//, '');
36
+ const absPath = joinPath(projectRoot, filePath);
37
+ try {
38
+ const content = await fs.readFile(absPath);
39
+ return {
40
+ contents: [{
41
+ uri: uri.href,
42
+ mimeType: 'text/markdown',
43
+ text: content,
44
+ }],
45
+ };
46
+ }
47
+ catch {
48
+ return {
49
+ contents: [{
50
+ uri: uri.href,
51
+ mimeType: 'text/plain',
52
+ text: `Error: File not found: ${filePath}`,
53
+ }],
54
+ };
55
+ }
56
+ });
57
+ // 3. Scope — all organons at a scope level
58
+ server.resource('organon-scope', 'organon://scope/{scope}', async (uri) => {
59
+ const scope = uri.pathname.replace(/^\//, '');
60
+ const result = await query({
61
+ projectRoot,
62
+ config,
63
+ fs,
64
+ scope,
65
+ verbose: false,
66
+ });
67
+ const scopeData = result.files.map((f) => ({
68
+ path: f.path,
69
+ type: f.frontmatter?.type,
70
+ name: f.frontmatter?.name,
71
+ summary: f.frontmatter?.summary,
72
+ token_estimate: f.frontmatter?.token_estimate,
73
+ }));
74
+ return {
75
+ contents: [{
76
+ uri: uri.href,
77
+ mimeType: 'application/json',
78
+ text: JSON.stringify(scopeData, null, 2),
79
+ }],
80
+ };
81
+ });
82
+ // 4. Health — quick health summary
83
+ server.resource('organon-health', 'organon://health', async (uri) => {
84
+ const result = await health({
85
+ projectRoot,
86
+ config,
87
+ fs,
88
+ fixSuggestions: true,
89
+ });
90
+ const summary = {
91
+ score: result.score,
92
+ coverage: result.coverage,
93
+ validation: result.validation,
94
+ tokens: result.tokens,
95
+ freshness: {
96
+ fresh: result.freshness.fresh,
97
+ stale: result.freshness.stale,
98
+ unknown: result.freshness.unknown,
99
+ },
100
+ topIssues: result.issues.slice(0, 10),
101
+ };
102
+ return {
103
+ contents: [{
104
+ uri: uri.href,
105
+ mimeType: 'application/json',
106
+ text: JSON.stringify(summary, null, 2),
107
+ }],
108
+ };
109
+ });
110
+ }
111
+ //# sourceMappingURL=resources.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resources.js","sourceRoot":"","sources":["../../src/mcp/resources.ts"],"names":[],"mappings":"AAAA;;GAEG;AAIH,OAAO,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AACzC,OAAO,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAG7C,MAAM,UAAU,iBAAiB,CAC/B,MAAiB,EACjB,WAAmB,EACnB,MAAqB,EACrB,EAAc;IAEd,0DAA0D;IAC1D,MAAM,CAAC,Q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;IACJ,CAAC,CACF,CAAC;IAEF,mCAAmC;IACnC,MAAM,CAAC,QAAQ,CACb,gBAAgB,EAChB,kBAAkB,EAClB,KAAK,EAAE,GAAG,EAAE,EAAE;QACZ,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC;YAC1B,WAAW;YACX,MAAM;YACN,EAAE;YACF,cAAc,EAAE,IAAI;SACrB,CAAC,CAAC;QAEH,MAAM,OAAO,GAAG;YACd,KAAK,EAAE,MAAM,CAAC,KAAK;YACnB,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,UAAU,EAAE,MAAM,CAAC,UAAU;YAC7B,MAAM,EAAE,MAAM,CAAC,MAAM;YACrB,SAAS,EAAE;gBACT,KAAK,EAAE,MAAM,CAAC,SAAS,CAAC,KAAK;gBAC7B,KAAK,EAAE,MAAM,CAAC,SAAS,CAAC,KAAK;gBAC7B,OAAO,EAAE,MAAM,CAAC,SAAS,CAAC,OAAO;aAClC;YACD,SAAS,EAAE,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE,CAAC;SACtC,CAAC;QAEF,OAAO;YACL,QAAQ,EAAE,CAAC;oBACT,GAAG,EAAE,GAAG,CAAC,IAAI;oBACb,QAAQ,EAAE,kBAAkB;oBAC5B,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC;iBACvC,CAAC;SACH,CAAC;IACJ,CAAC,CACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * MCP Server — Organon methodology tools exposed via Model Context Protocol.
3
+ *
4
+ * Runs on stdio transport. Started via `organon mcp` command.
5
+ */
6
+ export declare function startServer(projectRoot: string, configPath?: string): Promise<void>;
7
+ //# sourceMappingURL=server.d.ts.map