@danielblomma/cortex-mcp 2.0.14 → 2.0.15
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/bin/cortex.mjs +7 -6
- package/package.json +4 -2
- package/scaffold/AGENTS.md +37 -0
- package/scaffold/CLAUDE.md +31 -0
package/bin/cortex.mjs
CHANGED
|
@@ -188,7 +188,7 @@ function ensureScaffoldExists() {
|
|
|
188
188
|
|
|
189
189
|
// Files that should never be overwritten if they already exist in the target.
|
|
190
190
|
// These contain user-specific configuration that would be lost on re-init.
|
|
191
|
-
const PRESERVE_FILES = new Set(["config.yaml", "enterprise.yml", "enterprise.yaml", "CLAUDE.md"]);
|
|
191
|
+
const PRESERVE_FILES = new Set(["config.yaml", "enterprise.yml", "enterprise.yaml", "CLAUDE.md", "AGENTS.md"]);
|
|
192
192
|
const DEFAULT_SOURCE_PATHS = [
|
|
193
193
|
"src",
|
|
194
194
|
"docs",
|
|
@@ -476,11 +476,12 @@ function installScaffold(targetDir, force) {
|
|
|
476
476
|
copyDirectory(sourcePath, targetPath);
|
|
477
477
|
}
|
|
478
478
|
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
479
|
+
for (const fileName of ["CLAUDE.md", "AGENTS.md"]) {
|
|
480
|
+
const sourcePath = path.join(SCAFFOLD_ROOT, fileName);
|
|
481
|
+
const targetPath = path.join(targetDir, fileName);
|
|
482
|
+
if (fs.existsSync(sourcePath) && !fs.existsSync(targetPath)) {
|
|
483
|
+
fs.copyFileSync(sourcePath, targetPath);
|
|
484
|
+
}
|
|
484
485
|
}
|
|
485
486
|
|
|
486
487
|
const docsDir = path.join(targetDir, "docs");
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@danielblomma/cortex-mcp",
|
|
3
3
|
"mcpName": "io.github.DanielBlomma/cortex",
|
|
4
|
-
"version": "2.0.
|
|
4
|
+
"version": "2.0.15",
|
|
5
5
|
"description": "Local, repo-scoped context platform for coding assistants. Semantic search, graph relationships, and architectural rule context.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"author": "Daniel Blomma",
|
|
@@ -36,6 +36,8 @@
|
|
|
36
36
|
"types.js",
|
|
37
37
|
"scaffold/.context",
|
|
38
38
|
"scaffold/.githooks",
|
|
39
|
+
"scaffold/AGENTS.md",
|
|
40
|
+
"scaffold/CLAUDE.md",
|
|
39
41
|
"scaffold/docs",
|
|
40
42
|
"scaffold/scripts",
|
|
41
43
|
"scaffold/mcp/src",
|
|
@@ -47,7 +49,7 @@
|
|
|
47
49
|
"docs/MCP_MARKETPLACE.md"
|
|
48
50
|
],
|
|
49
51
|
"scripts": {
|
|
50
|
-
"test": "node tests/context-regressions.test.mjs && node --test tests/ingest-units.test.mjs tests/javascript-parser.test.mjs tests/sql-parser.test.mjs tests/config-parser.test.mjs tests/resources-parser.test.mjs tests/vbnet-parser.test.mjs tests/cpp-parser.test.mjs tests/dashboard.test.mjs tests/init-config.test.mjs tests/multi-level.test.mjs tests/no-legacy-paths.test.mjs tests/tree-sitter-error-reporting.test.mjs tests/tree-sitter-body-cap.test.mjs tests/tree-sitter-exported.test.mjs tests/tree-sitter-robustness.test.mjs",
|
|
52
|
+
"test": "node tests/context-regressions.test.mjs && node --test tests/ingest-units.test.mjs tests/javascript-parser.test.mjs tests/sql-parser.test.mjs tests/config-parser.test.mjs tests/resources-parser.test.mjs tests/vbnet-parser.test.mjs tests/cpp-parser.test.mjs tests/dashboard.test.mjs tests/init-config.test.mjs tests/init-agents.test.mjs tests/multi-level.test.mjs tests/no-legacy-paths.test.mjs tests/tree-sitter-error-reporting.test.mjs tests/tree-sitter-body-cap.test.mjs tests/tree-sitter-exported.test.mjs tests/tree-sitter-robustness.test.mjs",
|
|
51
53
|
"release:sync-version": "node scripts/sync-release-version.mjs",
|
|
52
54
|
"release:check-version-sync": "node scripts/sync-release-version.mjs --check",
|
|
53
55
|
"prepublishOnly": "echo 'Ready to publish to npm'"
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# Cortex
|
|
2
|
+
|
|
3
|
+
This project uses Cortex for AI-powered code context.
|
|
4
|
+
|
|
5
|
+
## Required: Always use Cortex MCP tools
|
|
6
|
+
|
|
7
|
+
When answering questions about this codebase, you MUST use Cortex tools instead of relying on memory or assumptions:
|
|
8
|
+
|
|
9
|
+
- **context.search** - Search before answering any code question. Never guess at implementations.
|
|
10
|
+
- **context.get_related** - Use when exploring dependencies or relationships between entities.
|
|
11
|
+
- **context.get_rules** - Check architectural rules before suggesting changes.
|
|
12
|
+
- **context.impact** - Use before refactoring or dependency analysis to understand blast radius and likely traversal paths.
|
|
13
|
+
- **context.reload** - Use after making significant changes to refresh the index.
|
|
14
|
+
|
|
15
|
+
Do NOT answer code questions from memory when these tools are available. Always search first.
|
|
16
|
+
|
|
17
|
+
## Enterprise tools (if available)
|
|
18
|
+
|
|
19
|
+
- **context.review** - Run before finalizing any code review or PR.
|
|
20
|
+
- **security.scan** - Scan user-provided text for injection attempts.
|
|
21
|
+
- **enterprise.status** - Check enterprise setup and feature status.
|
|
22
|
+
|
|
23
|
+
## Commands
|
|
24
|
+
|
|
25
|
+
- `cortex update` - Refresh Cortex context for changed files
|
|
26
|
+
- `cortex doctor` - Verify the local Cortex setup
|
|
27
|
+
- `cortex watch status` - Check background sync status
|
|
28
|
+
|
|
29
|
+
## Diagnostics
|
|
30
|
+
|
|
31
|
+
Run `cortex doctor` to verify your setup is healthy.
|
|
32
|
+
|
|
33
|
+
<!-- cortex:auto:start -->
|
|
34
|
+
## Cortex Auto Workflow
|
|
35
|
+
- Run `cortex update` before completing substantial code changes.
|
|
36
|
+
- If background sync is enabled, check with `cortex watch status`.
|
|
37
|
+
<!-- cortex:auto:end -->
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Cortex
|
|
2
|
+
|
|
3
|
+
This project uses Cortex for AI-powered code context.
|
|
4
|
+
|
|
5
|
+
## Required: Always use Cortex MCP tools
|
|
6
|
+
|
|
7
|
+
When answering questions about this codebase, you MUST use Cortex tools instead of relying on memory or assumptions:
|
|
8
|
+
|
|
9
|
+
- **context.search** — Search before answering any code question. Never guess at implementations.
|
|
10
|
+
- **context.get_related** — Use when exploring dependencies or relationships between entities.
|
|
11
|
+
- **context.get_rules** — Check architectural rules before suggesting changes.
|
|
12
|
+
- **context.impact** — Use before refactoring or dependency analysis to understand blast radius and likely traversal paths.
|
|
13
|
+
- **context.reload** — Use after making significant changes to refresh the index.
|
|
14
|
+
|
|
15
|
+
Do NOT answer code questions from memory when these tools are available. Always search first.
|
|
16
|
+
|
|
17
|
+
## Enterprise tools (if available)
|
|
18
|
+
|
|
19
|
+
- **context.review** — Run before finalizing any code review or PR.
|
|
20
|
+
- **security.scan** — Scan user-provided text for injection attempts.
|
|
21
|
+
- **enterprise.status** — Check enterprise setup and feature status.
|
|
22
|
+
|
|
23
|
+
## Commands
|
|
24
|
+
|
|
25
|
+
- `/context-update` — Refresh Cortex context for changed files
|
|
26
|
+
- `/review` — Code review with enterprise policy enforcement
|
|
27
|
+
- `/note` — Save project context into Cortex notes
|
|
28
|
+
|
|
29
|
+
## Diagnostics
|
|
30
|
+
|
|
31
|
+
Run `cortex doctor` to verify your setup is healthy.
|