@ryuenn3123/agentic-senior-core 3.0.39 → 3.0.41

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.
@@ -7,7 +7,7 @@ This prompt boots a repository with strict AI coding guidance context.
7
7
  When a new project is created or initialized, the agent must automatically:
8
8
  1. Read [AGENTS.md](../../AGENTS.md) to understand the canonical bootstrap chain and active entrypoints.
9
9
  2. Resolve the smallest relevant rule set from [.agent-context/rules/](../rules/) instead of scanning the whole directory by default.
10
- 3. Review dynamic runtime signals from [.agent-context/state/onboarding-report.json](../state/onboarding-report.json), [.agent-context/state/stack-research-snapshot.json](../state/stack-research-snapshot.json), repository evidence, and task constraints.
10
+ 3. Review dynamic runtime signals from [.agent-context/state/onboarding-report.json](../state/onboarding-report.json), repository evidence, task constraints, and live official documentation when runtime or ecosystem facts matter.
11
11
  4. If Docker or Compose is in scope, load [docker-runtime.md](../rules/docker-runtime.md) and verify the latest official Docker guidance before authoring container assets.
12
12
  5. For unresolved framework or package setup, recommend the latest stable compatible dependency set and official framework setup flow from live official documentation before coding unless a documented compatibility constraint blocks it.
13
13
 
@@ -15,6 +15,7 @@ Before editing:
15
15
  7. Enforce backend universal principles: no clever hacks, no premature abstraction, readability over brevity.
16
16
  8. For backend/API scope, enforce layered boundaries, zero-trust input validation, safe centralized error responses, bounded list reads, transaction safety for multi-write mutations, idempotency for sensitive mutations, and behavior-focused API tests.
17
17
  9. Backend/API governance is global and stack-agnostic. Do not create stack-specific adapters or framework-specific rule branches; apply the global rules through the framework already present in the target project.
18
+ 10. Enforce the complexity budget: choose fewer moving parts only when behavior, safety, clarity, and maintainability stay intact.
18
19
 
19
20
  Refactor rules:
20
21
  - Improve clarity, boundaries, naming, validation, error handling, tests, and docs.
@@ -23,6 +24,9 @@ Refactor rules:
23
24
  - Keep module boundaries explicit and project-specific.
24
25
  - Split large files when the split makes the flow easier to understand.
25
26
  - Do not introduce abstractions before the repeated pattern is real.
27
+ - Remove code that does not carry behavior, safety, clarity, maintainability, or test value.
28
+ - Prefer the shorter implementation only when it keeps the same guarantees.
29
+ - Run a final simplification pass before completion.
26
30
  - Update tests and docs whenever behavior contracts, public APIs, data shape, or UI contracts change.
27
31
 
28
32
  For every meaningful change, explain:
@@ -25,6 +25,7 @@ Run this before declaring a task done. Apply only the sections relevant to the c
25
25
  - [ ] No clever hacks in backend and shared core modules
26
26
  - [ ] No premature abstraction (base classes/util layers created only after repeated stable patterns)
27
27
  - [ ] Readability over brevity for maintainability
28
+ - [ ] Complexity budget was applied: equivalent behavior uses fewer moving parts without losing validation, error handling, fallbacks, accessibility, tests, or security boundaries.
28
29
  - [ ] Controllers, route handlers, and transport adapters do not contain business policy, raw queries, or cross-resource orchestration.
29
30
  - [ ] Services or use cases own business flow, transaction boundaries, and mutation safety.
30
31
  - [ ] Repositories or adapters own persistence/external IO details without hiding business decisions.
@@ -12,6 +12,19 @@ These principles are mandatory for backend and shared core modules.
12
12
  - Keep transport, application, domain, and infrastructure concerns separated.
13
13
  - Favor explicit module boundaries over hidden cross-layer shortcuts.
14
14
 
15
+ ## Complexity Budget (Mandatory)
16
+
17
+ Prefer the smallest clear implementation that fully preserves behavior, safety, and maintainability.
18
+
19
+ - If two implementations are equivalent in behavior and quality, choose the one with fewer moving parts.
20
+ - Remove code that does not carry behavior, safety, clarity, maintainability, or test value.
21
+ - Prefer direct logic over extra wrappers, layers, classes, config, or state when the abstraction does not reduce real complexity.
22
+ - Keep validation, error handling, fallback paths, accessibility, tests, security boundaries, and observability when they protect real behavior.
23
+ - Run a final simplification pass before completion.
24
+ - Do not optimize for line count alone.
25
+ - Do not replace clear code with clever, dense, or surprising code.
26
+ - Do not remove safeguards just because the happy path works.
27
+
15
28
  ## Universal SOP Baseline (Mandatory)
16
29
 
17
30
  The `.agent-context/rules/` directory is the default guidance source for implementation and review.
@@ -91,6 +104,7 @@ Service separation only makes sense when multiple signals are true, such as:
91
104
  - Cross-cutting utilities belong in explicit shared locations, not scattered feature internals.
92
105
  - Files above roughly 1000 lines are a refactor trigger, not a success signal.
93
106
  - Preserve one clear public entrypoint per module when helpful, but move implementation into smaller focused files.
107
+ - Keep code compact because the design is understood, not because safeguards were removed.
94
108
 
95
109
  ## Module Communication
96
110
 
@@ -8,11 +8,9 @@ Tracked seed/config artifacts:
8
8
  - `benchmark-comparison-schema.json`
9
9
  - `benchmark-reproducibility.json`
10
10
  - `benchmark-thresholds.json`
11
- - `benchmark-watchlist.json`
12
11
  - `benchmark-writer-judge-config.json`
13
12
  - `memory-adapter-contract.json`
14
13
  - `memory-schema-v1.json`
15
- - `stack-research-snapshot.json`
16
14
 
17
15
  Tracked operational artifact:
18
16
  - `onboarding-report.json` stays tracked in this repository because internal audits read it as the current repository onboarding state. In installed projects, `init` and `upgrade` regenerate this file.
@@ -23,4 +21,4 @@ Local-only/generated artifacts:
23
21
  - `llm-judge-report.json`
24
22
  - benchmark, trend, weekly governance, and quality report outputs
25
23
 
26
- Do not treat generated reports as current project truth. Rerun the matching `npm run benchmark:*`, `npm run report:*`, or `npm run audit:*` command when fresh evidence is needed.
24
+ Do not treat generated reports or archived research as current project truth. Rerun the matching `npm run benchmark:*`, `npm run report:*`, or `npm run audit:*` command when fresh evidence is needed.
@@ -59,12 +59,12 @@
59
59
  "inputReferences": [
60
60
  "scripts/release-gate.mjs",
61
61
  "scripts/benchmark-intelligence.mjs",
62
- ".agent-context/state/benchmark-watchlist.json"
62
+ "scripts/benchmark-gate.mjs"
63
63
  ],
64
64
  "expectedSignals": [
65
65
  "release readiness",
66
- "competitive coverage",
67
- "SLA freshness"
66
+ "static external watchlist retirement",
67
+ "no stale benchmark research dependency"
68
68
  ],
69
69
  "primaryCommand": "npm run benchmark:intelligence"
70
70
  }
@@ -72,7 +72,7 @@
72
72
  "rerunInstructions": [
73
73
  "Run npm run benchmark:detection to regenerate detection benchmark output.",
74
74
  "Run npm run benchmark:gate to validate benchmark anti-regression thresholds.",
75
- "Run npm run benchmark:intelligence to validate benchmark watchlist freshness.",
75
+ "Run npm run benchmark:intelligence to confirm static external benchmark watchlists stay retired.",
76
76
  "Run npm run benchmark:bundle to emit a reproducible benchmark evidence bundle.",
77
77
  "Run npm run benchmark:writer-judge to emit writer-judge side-by-side matrix output."
78
78
  ],
package/.cursorrules CHANGED
@@ -1,6 +1,6 @@
1
1
  # .cursorrules - Legacy Thin Adapter
2
2
 
3
- Generated by Agentic-Senior-Core CLI v3.0.39
3
+ Generated by Agentic-Senior-Core CLI v3.0.41
4
4
  Adapter Mode: legacy-thin
5
5
  Adapter Source: .agent-instructions.md when present; fallback .instructions.md
6
6
  Canonical baseline: .instructions.md
package/.windsurfrules CHANGED
@@ -1,6 +1,6 @@
1
1
  # .windsurfrules - Legacy Thin Adapter
2
2
 
3
- Generated by Agentic-Senior-Core CLI v3.0.39
3
+ Generated by Agentic-Senior-Core CLI v3.0.41
4
4
  Adapter Mode: legacy-thin
5
5
  Adapter Source: .agent-instructions.md when present; fallback .instructions.md
6
6
  Canonical baseline: .instructions.md
package/CONTRIBUTING.md CHANGED
@@ -88,7 +88,6 @@ If all three are "yes", it belongs here.
88
88
  - Generic content that reads like it was auto-generated without thought
89
89
  - Rules without concrete enforcement boundaries
90
90
  - Stack profiles for languages the author doesn't actually use in production
91
- - Blueprints that are just folder structures without code patterns
92
91
  - PRs that don't update the relevant source files, generated adapters, and checklists
93
92
 
94
93
  ---
@@ -97,6 +96,13 @@ If all three are "yes", it belongs here.
97
96
 
98
97
  The npm package is published under `@ryuenn3123`, while the GitHub repository is hosted under `fatidaprilian`.
99
98
 
99
+ ### Architecture Boundaries
100
+
101
+ When contributing code to the CLI or the maintenance tools, respect the boundary between `lib/` and `scripts/`:
102
+
103
+ - **`lib/`**: Contains the core CLI application logic. These files are executed by the package binary but are **never** copied into target user workspaces.
104
+ - **`scripts/`**: Contains standalone tools (like validators, audits, and benchmarks) AND the MCP server (`scripts/mcp-server.mjs`). Code here must not depend on `lib/` because some scripts (like the MCP server) are copied directly to target workspaces where `lib/` does not exist.
105
+
100
106
  ```bash
101
107
  # Clone
102
108
  git clone https://github.com/fatidaprilian/Agentic-Senior-Core.git
package/README.md CHANGED
@@ -10,12 +10,12 @@
10
10
  **Production-grade Rules Engine (Governance Engine) for AI coding agents.**
11
11
  Works with Cursor, Windsurf, GitHub Copilot, Claude Code, Gemini, and other LLM-powered IDE workflows.
12
12
 
13
- Latest release: 3.0.39 (2026-04-30).
13
+ Latest release: 3.0.40 (2026-04-30).
14
14
 
15
- Highlights in 3.0.39:
16
- - Post-release hygiene removes stale V2 evidence-bundle and Bun lockfile drift surfaces.
17
- - Package and lockfile validation now blocks version drift and accidental dual package-manager state.
18
- - Repo-local agent context now documents frontend/backend governance boundaries and anti-grid wallpaper handling.
15
+ Highlights in 3.0.40:
16
+ - Adds a mandatory complexity budget so agents choose fewer moving parts only when quality stays intact.
17
+ - Refactor guidance now requires a final simplification pass before completion.
18
+ - Release tooling keeps legacy root adapter version metadata aligned with package bumps.
19
19
 
20
20
  </div>
21
21
 
@@ -131,7 +131,7 @@ Full mapping reference: docs/terminology-mapping.md
131
131
 
132
132
  - FAQ: docs/faq.md
133
133
  - Deep dive internals: docs/deep-dive.md
134
- - V2 upgrade playbook: docs/v2-upgrade-playbook.md
134
+ - Archived V2 upgrade playbook: docs/archive/v2-upgrade-playbook.md
135
135
  - Integration playbook: docs/integration-playbook.md
136
136
  - Benchmark and stack reference: docs/benchmark-reference.md
137
137
  - Terminology mapping reference: docs/terminology-mapping.md
@@ -2,9 +2,7 @@ import fs from 'node:fs/promises';
2
2
  import path from 'node:path';
3
3
  import crypto from 'node:crypto';
4
4
  import { pathExists, ensureDirectory } from './utils.mjs';
5
- import { entryPointFiles } from './constants.mjs';
6
-
7
- const BACKUP_DIR_NAME = '.agentic-backup';
5
+ import { entryPointFiles, BACKUP_DIR_NAME } from './constants.mjs';
8
6
 
9
7
  /**
10
8
  * Calculates a SHA-256 hash of a file's contents.
@@ -81,7 +81,7 @@ import {
81
81
  resolveSilentCiGuardrailsDefault,
82
82
  } from './init/setup-decisions.mjs';
83
83
 
84
- export { REPO_ROOT } from '../constants.mjs';
84
+ export { REPOSITORY_ROOT } from '../constants.mjs';
85
85
  export {
86
86
  parseInitArguments,
87
87
  normalizeRuntimeEnvironmentKey,
@@ -9,10 +9,10 @@ import { fileURLToPath } from 'node:url';
9
9
  const currentFilePath = fileURLToPath(import.meta.url);
10
10
  const currentDirectoryPath = dirname(currentFilePath);
11
11
 
12
- export const REPO_ROOT = resolve(currentDirectoryPath, '..', '..');
13
- export const PACKAGE_JSON_PATH = join(REPO_ROOT, 'package.json');
12
+ export const REPOSITORY_ROOT = resolve(currentDirectoryPath, '..', '..');
13
+ export const PACKAGE_JSON_PATH = join(REPOSITORY_ROOT, 'package.json');
14
14
  export const CLI_VERSION = JSON.parse(readFileSync(PACKAGE_JSON_PATH, 'utf8')).version;
15
- export const AGENT_CONTEXT_DIR = join(REPO_ROOT, '.agent-context');
15
+ export const AGENT_CONTEXT_DIR = join(REPOSITORY_ROOT, '.agent-context');
16
16
  export const POLICY_FILE_NAME = 'llm-judge-threshold.json';
17
17
 
18
18
  export const ALLOWED_SEVERITY_LEVELS = new Set(['critical', 'high', 'medium', 'low']);
@@ -140,3 +140,5 @@ export const entryPointFiles = [
140
140
  ];
141
141
 
142
142
  export const directoryCopies = ['.agent-context', '.gemini', '.agents'];
143
+
144
+ export const BACKUP_DIR_NAME = '.agentic-backup';
@@ -1,8 +1,7 @@
1
1
  import fs from 'node:fs/promises';
2
2
  import path from 'node:path';
3
3
  import { pathExists, ensureDirectory } from './utils.mjs';
4
-
5
- const BACKUP_DIR_NAME = '.agentic-backup';
4
+ import { BACKUP_DIR_NAME } from './constants.mjs';
6
5
 
7
6
  /**
8
7
  * Performs a rollback of a target directory using the backup manifest.
@@ -2,7 +2,7 @@ import fs from 'node:fs/promises';
2
2
  import path from 'node:path';
3
3
 
4
4
  import {
5
- REPO_ROOT,
5
+ REPOSITORY_ROOT,
6
6
  entryPointFiles,
7
7
  directoryCopies,
8
8
  } from '../constants.mjs';
@@ -102,7 +102,7 @@ async function buildManagedSourceManifest(options = {}) {
102
102
  const sourceDirectories = new Set();
103
103
 
104
104
  for (const sourceDirectoryName of directoryCopies) {
105
- const sourceDirectoryPath = path.join(REPO_ROOT, sourceDirectoryName);
105
+ const sourceDirectoryPath = path.join(REPOSITORY_ROOT, sourceDirectoryName);
106
106
  const sourceTreeEntries = await collectRelativeTreeEntries(sourceDirectoryPath, sourceDirectoryName);
107
107
 
108
108
  for (const sourceFilePath of sourceTreeEntries.files) {
@@ -115,7 +115,7 @@ async function buildManagedSourceManifest(options = {}) {
115
115
  }
116
116
 
117
117
  for (const entryPointFileName of entryPointFiles) {
118
- const sourceFilePath = path.join(REPO_ROOT, entryPointFileName);
118
+ const sourceFilePath = path.join(REPOSITORY_ROOT, entryPointFileName);
119
119
  if (!(await pathExists(sourceFilePath))) {
120
120
  continue;
121
121
  }
@@ -123,7 +123,7 @@ async function buildManagedSourceManifest(options = {}) {
123
123
  sourceFiles.add(toPosixRelativePath(entryPointFileName));
124
124
  }
125
125
 
126
- const optionalManagedEntries = await collectOptionalManagedEntries(REPO_ROOT, options);
126
+ const optionalManagedEntries = await collectOptionalManagedEntries(REPOSITORY_ROOT, options);
127
127
  for (const sourceFilePath of optionalManagedEntries.files) {
128
128
  sourceFiles.add(sourceFilePath);
129
129
  }
package/lib/cli/utils.mjs CHANGED
@@ -7,7 +7,7 @@ import path from 'node:path';
7
7
  import os from 'node:os';
8
8
 
9
9
  import {
10
- REPO_ROOT,
10
+ REPOSITORY_ROOT,
11
11
  ALLOWED_SEVERITY_LEVELS,
12
12
  PROFILE_PRESETS,
13
13
  INIT_PRESETS,
@@ -144,14 +144,14 @@ export async function copyGovernanceAssetsToTarget(
144
144
  const preservedFiles = [];
145
145
 
146
146
  for (const sourceDirectoryName of directoryCopies) {
147
- const sourceDirectoryPath = path.join(REPO_ROOT, sourceDirectoryName);
147
+ const sourceDirectoryPath = path.join(REPOSITORY_ROOT, sourceDirectoryName);
148
148
  if (!(await pathExists(sourceDirectoryPath))) {
149
149
  continue;
150
150
  }
151
151
 
152
152
  const sourceTree = await collectRelativeTreeEntries(sourceDirectoryPath, sourceDirectoryName);
153
153
  for (const relativeFilePath of sourceTree.files) {
154
- const sourcePath = path.join(REPO_ROOT, ...relativeFilePath.split('/'));
154
+ const sourcePath = path.join(REPOSITORY_ROOT, ...relativeFilePath.split('/'));
155
155
  const targetPath = path.join(resolvedTargetDirectoryPath, ...relativeFilePath.split('/'));
156
156
  const syncResult = await syncFile(sourcePath, targetPath, {
157
157
  preserveUserOwned: sourceDirectoryName === '.gemini',
@@ -165,7 +165,7 @@ export async function copyGovernanceAssetsToTarget(
165
165
  }
166
166
 
167
167
  for (const entryPointFileName of entryPointFiles) {
168
- const sourceFilePath = path.join(REPO_ROOT, entryPointFileName);
168
+ const sourceFilePath = path.join(REPOSITORY_ROOT, entryPointFileName);
169
169
  const targetFilePath = path.join(resolvedTargetDirectoryPath, entryPointFileName);
170
170
 
171
171
  if (!(await pathExists(sourceFilePath))) {
@@ -211,13 +211,13 @@ export async function copyGovernanceAssetsToTarget(
211
211
  const projectName = path.basename(resolvedTargetDirectoryPath);
212
212
  const mcpArgs = ['./scripts/mcp-server.mjs'];
213
213
 
214
- const sourceMcpServerPath = path.join(REPO_ROOT, 'scripts', 'mcp-server.mjs');
214
+ const sourceMcpServerPath = path.join(REPOSITORY_ROOT, 'scripts', 'mcp-server.mjs');
215
215
  const targetMcpServerPath = path.join(resolvedTargetDirectoryPath, 'scripts', 'mcp-server.mjs');
216
216
  const mcpServerSync = await syncFile(sourceMcpServerPath, targetMcpServerPath);
217
217
  if (mcpServerSync.status === 'created') createdFiles.push('scripts/mcp-server.mjs');
218
218
  else if (mcpServerSync.status === 'updated') updatedFiles.push('scripts/mcp-server.mjs');
219
219
 
220
- const sourceMcpHelpersDirectoryPath = path.join(REPO_ROOT, 'scripts', 'mcp-server');
220
+ const sourceMcpHelpersDirectoryPath = path.join(REPOSITORY_ROOT, 'scripts', 'mcp-server');
221
221
  if (await pathExists(sourceMcpHelpersDirectoryPath)) {
222
222
  const mcpHelperTreeEntries = await collectRelativeTreeEntries(
223
223
  sourceMcpHelpersDirectoryPath,
@@ -225,7 +225,7 @@ export async function copyGovernanceAssetsToTarget(
225
225
  );
226
226
 
227
227
  for (const relativeHelperFilePath of mcpHelperTreeEntries.files) {
228
- const sourceHelperFilePath = path.join(REPO_ROOT, ...relativeHelperFilePath.split('/'));
228
+ const sourceHelperFilePath = path.join(REPOSITORY_ROOT, ...relativeHelperFilePath.split('/'));
229
229
  const targetHelperFilePath = path.join(resolvedTargetDirectoryPath, ...relativeHelperFilePath.split('/'));
230
230
  const helperSyncResult = await syncFile(sourceHelperFilePath, targetHelperFilePath);
231
231
 
@@ -303,8 +303,13 @@ export async function copyGovernanceAssetsToTarget(
303
303
  try {
304
304
  const globalGeminiDir = path.join(os.homedir(), '.gemini', 'antigravity');
305
305
  const globalGeminiMcpPath = path.join(globalGeminiDir, 'mcp_config.json');
306
-
307
- if (await pathExists(globalGeminiDir)) {
306
+ const targetMcpServerScript = path.join(resolvedTargetDirectoryPath, 'scripts', 'mcp-server.mjs');
307
+
308
+ // Only inject if the MCP server script will actually exist at the target.
309
+ // When the script is missing, Antigravity blocks all chat instead of degrading gracefully.
310
+ const targetHasMcpServer = await pathExists(targetMcpServerScript);
311
+
312
+ if (targetHasMcpServer && await pathExists(globalGeminiDir)) {
308
313
  let geminiConfig = { mcpServers: {} };
309
314
  if (await pathExists(globalGeminiMcpPath)) {
310
315
  const content = await fs.readFile(globalGeminiMcpPath, 'utf8');
@@ -313,7 +318,20 @@ export async function copyGovernanceAssetsToTarget(
313
318
  }
314
319
  }
315
320
  if (!geminiConfig.mcpServers) geminiConfig.mcpServers = {};
316
-
321
+
322
+ // Prune stale agentic-senior-core entries whose workspace no longer exists
323
+ let configChanged = false;
324
+ for (const serverName of Object.keys(geminiConfig.mcpServers)) {
325
+ if (!serverName.startsWith('agentic-senior-core-')) continue;
326
+ const serverEntry = geminiConfig.mcpServers[serverName];
327
+ if (!serverEntry?.cwd) continue;
328
+ const staleMcpScript = path.join(serverEntry.cwd, 'scripts', 'mcp-server.mjs');
329
+ if (!(await pathExists(staleMcpScript))) {
330
+ delete geminiConfig.mcpServers[serverName];
331
+ configChanged = true;
332
+ }
333
+ }
334
+
317
335
  const safeProjectName = projectName.replace(/[^a-zA-Z0-9_-]/g, '-');
318
336
  const uniqueServerName = `agentic-senior-core-${safeProjectName}`;
319
337
  const templateServer = {
@@ -324,7 +342,11 @@ export async function copyGovernanceAssetsToTarget(
324
342
 
325
343
  if (JSON.stringify(geminiConfig.mcpServers[uniqueServerName]) !== JSON.stringify(templateServer)) {
326
344
  geminiConfig.mcpServers[uniqueServerName] = templateServer;
327
- await fs.writeFile(globalGeminiMcpPath, JSON.stringify(geminiConfig, null, 2) + '\n', 'utf8');
345
+ configChanged = true;
346
+ }
347
+
348
+ if (configChanged) {
349
+ await fs.writeFile(globalGeminiMcpPath, JSON.stringify(geminiConfig, null, 2) + '\n', 'utf8');
328
350
  }
329
351
  }
330
352
  } catch { /* Ignore global injection errors */ }
package/mcp.json CHANGED
@@ -13,31 +13,44 @@
13
13
  },
14
14
  "stack-strategies": {
15
15
  "path": "dynamic",
16
- "count": 0,
17
- "autoLoad": true
16
+ "autoLoad": true,
17
+ "type": "virtual"
18
18
  },
19
19
  "architecture-playbooks": {
20
20
  "path": "dynamic",
21
- "count": 0,
22
- "autoLoad": true
21
+ "autoLoad": true,
22
+ "type": "virtual"
23
23
  },
24
24
  "execution-contracts": {
25
25
  "path": "dynamic",
26
- "count": 0,
27
26
  "autoLoad": true,
28
- "sources": ["prompts", "review-checklists", "policies"]
27
+ "sources": [
28
+ "prompts",
29
+ "review-checklists",
30
+ "policies"
31
+ ],
32
+ "type": "virtual"
29
33
  },
30
34
  "prompts": {
31
35
  "path": ".agent-context/prompts",
32
36
  "count": 4,
33
37
  "autoLoad": true,
34
- "templates": ["init-project", "bootstrap-design", "refactor", "review-code"]
38
+ "templates": [
39
+ "init-project",
40
+ "bootstrap-design",
41
+ "refactor",
42
+ "review-code"
43
+ ]
35
44
  },
36
45
  "governance-modes": {
37
46
  "path": "dynamic",
38
- "count": 0,
39
47
  "autoLoad": true,
40
- "governance": ["platform", "regulated", "startup"]
48
+ "governance": [
49
+ "platform",
50
+ "regulated",
51
+ "startup"
52
+ ],
53
+ "type": "virtual"
41
54
  },
42
55
  "state": {
43
56
  "path": ".agent-context/state",
@@ -53,25 +66,24 @@
53
66
  "path": "docs",
54
67
  "count": 0,
55
68
  "autoLoad": false,
56
- "sources": ["project-brief", "architecture-decision-record", "flow-overview", "api-contract", "database-schema", "DESIGN", "design-intent"]
69
+ "sources": [
70
+ "project-brief",
71
+ "architecture-decision-record",
72
+ "flow-overview",
73
+ "api-contract",
74
+ "database-schema",
75
+ "DESIGN",
76
+ "design-intent"
77
+ ]
57
78
  }
58
79
  }
59
80
  },
60
- "servers": {
61
- "lint": {
62
- "command": "node",
63
- "args": ["./scripts/validate.mjs"],
64
- "transport": "stdio"
65
- },
66
- "test": {
67
- "command": "node",
68
- "args": ["--test", "./tests/cli-smoke.test.mjs", "./tests/llm-judge.test.mjs"],
69
- "transport": "stdio"
70
- }
71
- },
72
81
  "workflows": {
73
82
  "self-heal-on-failure": {
74
- "trigger": ["ci.failure", "lint.failure"],
83
+ "trigger": [
84
+ "ci.failure",
85
+ "lint.failure"
86
+ ],
75
87
  "steps": [
76
88
  "collect_logs",
77
89
  "map_violation_to_rule",
@@ -80,7 +92,10 @@
80
92
  ]
81
93
  },
82
94
  "full-knowledge-injection": {
83
- "trigger": ["workspace.initialize", "agent.start"],
95
+ "trigger": [
96
+ "workspace.initialize",
97
+ "agent.start"
98
+ ],
84
99
  "steps": [
85
100
  "resolve_scope_first",
86
101
  "inject_relevant_rules",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ryuenn3123/agentic-senior-core",
3
- "version": "3.0.39",
3
+ "version": "3.0.41",
4
4
  "type": "module",
5
5
  "description": "Force your AI Agent to code like a Staff Engineer, not a Junior.",
6
6
  "bin": {
@@ -21,11 +21,9 @@
21
21
  ".agent-context/state/benchmark-comparison-schema.json",
22
22
  ".agent-context/state/benchmark-reproducibility.json",
23
23
  ".agent-context/state/benchmark-thresholds.json",
24
- ".agent-context/state/benchmark-watchlist.json",
25
24
  ".agent-context/state/benchmark-writer-judge-config.json",
26
25
  ".agent-context/state/memory-adapter-contract.json",
27
26
  ".agent-context/state/memory-schema-v1.json",
28
- ".agent-context/state/stack-research-snapshot.json",
29
27
  ".agents/",
30
28
  ".cursor/",
31
29
  ".github/",
@@ -85,6 +83,6 @@
85
83
  "report:governance-weekly": "node ./scripts/governance-weekly-report.mjs",
86
84
  "clean:local": "node ./scripts/clean-local-artifacts.mjs",
87
85
  "validate": "node ./scripts/validate.mjs",
88
- "test": "node --test ./tests/cli-smoke.test.mjs ./tests/mcp-server.test.mjs ./tests/llm-judge.test.mjs ./tests/ui-rubric-calibration.test.mjs ./tests/operations.test.mjs"
86
+ "test": "node --test ./tests/cli-smoke.test.mjs ./tests/mcp-server.test.mjs ./tests/llm-judge.test.mjs ./tests/ui-rubric-calibration.test.mjs ./tests/operations.test.mjs ./tests/knowledge-injection.test.mjs"
89
87
  }
90
88
  }
@@ -22,7 +22,6 @@ const isStdoutOnlyMode = ARGUMENT_FLAGS.has('--stdout-only');
22
22
  const PACKAGE_JSON_PATH = join(REPOSITORY_ROOT, 'package.json');
23
23
  const REPRO_PROFILE_PATH = join(REPOSITORY_ROOT, '.agent-context', 'state', 'benchmark-reproducibility.json');
24
24
  const BENCHMARK_THRESHOLD_PATH = join(REPOSITORY_ROOT, '.agent-context', 'state', 'benchmark-thresholds.json');
25
- const BENCHMARK_WATCHLIST_PATH = join(REPOSITORY_ROOT, '.agent-context', 'state', 'benchmark-watchlist.json');
26
25
  const MEMORY_SCHEMA_PATH = join(REPOSITORY_ROOT, '.agent-context', 'state', 'memory-schema-v1.json');
27
26
  const MEMORY_ADAPTER_CONTRACT_PATH = join(REPOSITORY_ROOT, '.agent-context', 'state', 'memory-adapter-contract.json');
28
27
  const OUTPUT_PATH = join(REPOSITORY_ROOT, '.agent-context', 'state', 'benchmark-evidence-bundle.json');
@@ -233,6 +232,7 @@ function buildRubricSummary(thresholdConfiguration, intelligenceReport, memoryCo
233
232
  maximumManualCorrectionIncrease: thresholdConfiguration?.maximumManualCorrectionIncrease ?? null,
234
233
  },
235
234
  intelligenceSlaDays: intelligenceReport?.reviewSlaDays ?? null,
235
+ staticExternalWatchlistRetired: intelligenceReport?.staticExternalWatchlistRetired === true,
236
236
  reliabilityThresholds: RELIABILITY_THRESHOLDS,
237
237
  continuityThresholds: memoryContinuityReport?.thresholds || null,
238
238
  };
@@ -384,10 +384,6 @@ function buildHistorySnapshot({
384
384
  reliabilitySignals,
385
385
  securityIndicators,
386
386
  }) {
387
- const staleWatchlistCount = Array.isArray(benchmarkIntelligenceReport?.watchlist)
388
- ? benchmarkIntelligenceReport.watchlist.filter((watchlistEntry) => watchlistEntry?.stale === true).length
389
- : null;
390
-
391
387
  return {
392
388
  generatedAt,
393
389
  releaseVersion,
@@ -396,7 +392,7 @@ function buildHistorySnapshot({
396
392
  manualCorrectionRate: toFiniteNumber(detectionBenchmarkReport?.manualCorrectionRate, 0),
397
393
  benchmarkGatePassed: benchmarkGateReport?.passed === true,
398
394
  intelligencePassed: benchmarkIntelligenceReport?.passed === true,
399
- staleWatchlistCount,
395
+ staticExternalWatchlistRetired: benchmarkIntelligenceReport?.staticExternalWatchlistRetired === true,
400
396
  reliabilityPassed: reliabilitySignals.passed,
401
397
  reliabilityRiskLevel: reliabilitySignals.riskLevel,
402
398
  incorrectDetectionRate: reliabilitySignals.metrics.incorrectDetectionRate,
@@ -419,8 +415,6 @@ function buildReleaseDelta(historyEntries, currentSnapshot) {
419
415
 
420
416
  const top1AccuracyDelta = Number((currentSnapshot.top1Accuracy - previousReleaseSnapshot.top1Accuracy).toFixed(4));
421
417
  const manualCorrectionDelta = Number((currentSnapshot.manualCorrectionRate - previousReleaseSnapshot.manualCorrectionRate).toFixed(4));
422
- const staleWatchlistDelta =
423
- (toFiniteNumber(currentSnapshot.staleWatchlistCount, 0) - toFiniteNumber(previousReleaseSnapshot.staleWatchlistCount, 0));
424
418
  const vulnerabilityDelta =
425
419
  (toFiniteNumber(currentSnapshot.vulnerabilityTotal, 0) - toFiniteNumber(previousReleaseSnapshot.vulnerabilityTotal, 0));
426
420
 
@@ -433,12 +427,10 @@ function buildReleaseDelta(historyEntries, currentSnapshot) {
433
427
  },
434
428
  top1AccuracyDelta,
435
429
  manualCorrectionRateDelta: manualCorrectionDelta,
436
- staleWatchlistCountDelta: staleWatchlistDelta,
437
430
  vulnerabilityTotalDelta: vulnerabilityDelta,
438
431
  summary: [
439
432
  `top1Accuracy: ${top1AccuracyDelta >= 0 ? '+' : ''}${top1AccuracyDelta}`,
440
433
  `manualCorrectionRate: ${manualCorrectionDelta >= 0 ? '+' : ''}${manualCorrectionDelta}`,
441
- `staleWatchlistCount: ${staleWatchlistDelta >= 0 ? '+' : ''}${staleWatchlistDelta}`,
442
434
  `vulnerabilityTotal: ${vulnerabilityDelta >= 0 ? '+' : ''}${vulnerabilityDelta}`,
443
435
  ],
444
436
  };
@@ -453,7 +445,7 @@ function buildTrendTable(historyEntries) {
453
445
  manualCorrectionRate: historyEntry.manualCorrectionRate,
454
446
  incorrectDetectionRate: historyEntry.incorrectDetectionRate,
455
447
  lowConfidenceRate: historyEntry.lowConfidenceRate,
456
- staleWatchlistCount: historyEntry.staleWatchlistCount,
448
+ staticExternalWatchlistRetired: historyEntry.staticExternalWatchlistRetired === true,
457
449
  vulnerabilityTotal: historyEntry.vulnerabilityTotal,
458
450
  criticalVulnerabilityCount: historyEntry.criticalVulnerabilityCount,
459
451
  benchmarkGatePassed: historyEntry.benchmarkGatePassed,
@@ -470,7 +462,7 @@ function buildChartSeries(historyEntries) {
470
462
  manualCorrectionRate: historyEntries.map((historyEntry) => historyEntry.manualCorrectionRate),
471
463
  incorrectDetectionRate: historyEntries.map((historyEntry) => historyEntry.incorrectDetectionRate),
472
464
  lowConfidenceRate: historyEntries.map((historyEntry) => historyEntry.lowConfidenceRate),
473
- staleWatchlistCount: historyEntries.map((historyEntry) => historyEntry.staleWatchlistCount),
465
+ staticExternalWatchlistRetired: historyEntries.map((historyEntry) => historyEntry.staticExternalWatchlistRetired === true),
474
466
  vulnerabilityTotal: historyEntries.map((historyEntry) => historyEntry.vulnerabilityTotal),
475
467
  };
476
468
  }
@@ -503,7 +495,6 @@ function convertTrendTableToCsv(trendTable) {
503
495
  async function runBenchmarkEvidenceBundle() {
504
496
  const reproducibilityProfile = readJsonOrNull(REPRO_PROFILE_PATH);
505
497
  const thresholdConfiguration = readJsonOrNull(BENCHMARK_THRESHOLD_PATH);
506
- const watchlistConfiguration = readJsonOrNull(BENCHMARK_WATCHLIST_PATH);
507
498
  const memorySchemaConfiguration = readJsonOrNull(MEMORY_SCHEMA_PATH);
508
499
  const memoryAdapterContractConfiguration = readJsonOrNull(MEMORY_ADAPTER_CONTRACT_PATH);
509
500
  const releaseVersion = readReleaseVersion();
@@ -611,9 +602,10 @@ async function runBenchmarkEvidenceBundle() {
611
602
  rawInputs: {
612
603
  scenarios: Array.isArray(reproducibilityProfile?.scenarios) ? reproducibilityProfile.scenarios : [],
613
604
  benchmarkThresholds: thresholdConfiguration,
614
- benchmarkWatchlist: Array.isArray(watchlistConfiguration?.repositories)
615
- ? watchlistConfiguration.repositories
616
- : [],
605
+ benchmarkWatchlist: {
606
+ retired: true,
607
+ reason: 'Static external benchmark watchlists were removed to avoid stale or biasing research inputs.',
608
+ },
617
609
  memorySchema: memorySchemaConfiguration,
618
610
  memoryAdapterContract: memoryAdapterContractConfiguration,
619
611
  },
@@ -3,133 +3,26 @@
3
3
  /**
4
4
  * benchmark-intelligence.mjs
5
5
  *
6
- * Competitive intelligence cadence validator.
7
- * Ensures benchmark watchlist coverage and review freshness.
6
+ * Benchmark intelligence compatibility report.
7
+ * Static external watchlists were retired to avoid stale or biasing research inputs.
8
8
  */
9
9
 
10
- import { existsSync, readFileSync } from 'node:fs';
11
- import { dirname, join, resolve } from 'node:path';
12
- import { fileURLToPath } from 'node:url';
13
-
14
- const SCRIPT_FILE_PATH = fileURLToPath(import.meta.url);
15
- const SCRIPT_DIR = dirname(SCRIPT_FILE_PATH);
16
- const REPOSITORY_ROOT = resolve(SCRIPT_DIR, '..');
17
- const WATCHLIST_PATH = join(REPOSITORY_ROOT, '.agent-context', 'state', 'benchmark-watchlist.json');
18
- const REVIEW_SLA_DAYS = 14;
19
- const REQUIRED_BENCHMARK_REPOSITORIES = new Set([
20
- 'sickn33/antigravity-awesome-skills',
21
- 'github/awesome-copilot',
22
- 'MiniMax-AI/skills',
23
- ]);
24
-
25
- function parseDateOrNull(rawDateValue) {
26
- if (typeof rawDateValue !== 'string') {
27
- return null;
28
- }
29
-
30
- if (!/^\d{4}-\d{2}-\d{2}$/.test(rawDateValue)) {
31
- return null;
32
- }
33
-
34
- const parsedDate = new Date(`${rawDateValue}T00:00:00.000Z`);
35
- return Number.isNaN(parsedDate.getTime()) ? null : parsedDate;
36
- }
37
-
38
- function calculateAgeInDays(referenceDate, targetDate) {
39
- const ageInMilliseconds = referenceDate.getTime() - targetDate.getTime();
40
- return Math.floor(ageInMilliseconds / (1000 * 60 * 60 * 24));
41
- }
42
-
43
- function loadWatchlistConfiguration() {
44
- if (!existsSync(WATCHLIST_PATH)) {
45
- return { repositories: [] };
46
- }
47
-
48
- return JSON.parse(readFileSync(WATCHLIST_PATH, 'utf8'));
49
- }
50
-
51
10
  function runIntelligenceValidation() {
52
- const watchlistConfiguration = loadWatchlistConfiguration();
53
- const watchlistEntries = Array.isArray(watchlistConfiguration.repositories)
54
- ? watchlistConfiguration.repositories
55
- : [];
56
- const validationResults = [];
57
- const currentDate = new Date();
58
-
59
- const trackedRepositoryNames = new Set();
60
- for (const watchlistEntry of watchlistEntries) {
61
- trackedRepositoryNames.add(watchlistEntry.repository);
62
- }
63
-
64
- for (const requiredRepositoryName of REQUIRED_BENCHMARK_REPOSITORIES) {
65
- const hasRequiredRepository = trackedRepositoryNames.has(requiredRepositoryName);
66
- validationResults.push({
67
- checkName: 'required-benchmark-repository',
68
- repository: requiredRepositoryName,
69
- passed: hasRequiredRepository,
70
- details: hasRequiredRepository
71
- ? `${requiredRepositoryName} is present in watchlist`
72
- : `${requiredRepositoryName} is missing from watchlist`,
73
- });
74
- }
75
-
76
- const watchlistReport = watchlistEntries.map((watchlistEntry) => {
77
- const repositoryName = watchlistEntry.repository;
78
- const repositoryOwner = watchlistEntry.owner;
79
- const lastReviewedDate = parseDateOrNull(watchlistEntry.lastReviewedAt);
80
-
81
- const hasOwner = typeof repositoryOwner === 'string' && repositoryOwner.trim().length > 0;
82
- validationResults.push({
83
- checkName: 'watchlist-owner-defined',
84
- repository: repositoryName,
85
- passed: hasOwner,
86
- details: hasOwner ? `Owner ${repositoryOwner} is defined` : 'Owner is missing',
87
- });
88
-
89
- if (!lastReviewedDate) {
90
- validationResults.push({
91
- checkName: 'review-date-format',
92
- repository: repositoryName,
93
- passed: false,
94
- details: `Invalid or missing lastReviewedAt: ${String(watchlistEntry.lastReviewedAt)}`,
95
- });
96
-
97
- return {
98
- repository: repositoryName,
99
- owner: repositoryOwner,
100
- lastReviewedAt: watchlistEntry.lastReviewedAt,
101
- ageInDays: null,
102
- stale: true,
103
- };
104
- }
105
-
106
- const reviewAgeInDays = calculateAgeInDays(currentDate, lastReviewedDate);
107
- const reviewWithinSla = reviewAgeInDays <= REVIEW_SLA_DAYS;
108
-
109
- validationResults.push({
110
- checkName: 'review-sla-compliance',
111
- repository: repositoryName,
112
- passed: reviewWithinSla,
113
- details: `ageInDays=${reviewAgeInDays} slaDays=${REVIEW_SLA_DAYS}`,
114
- });
115
-
116
- return {
117
- repository: repositoryName,
118
- owner: repositoryOwner,
119
- lastReviewedAt: watchlistEntry.lastReviewedAt,
120
- ageInDays: reviewAgeInDays,
121
- stale: !reviewWithinSla,
122
- };
123
- });
124
-
125
- const failedCheckCount = validationResults.filter((validationResult) => !validationResult.passed).length;
11
+ const validationResults = [
12
+ {
13
+ checkName: 'static-external-watchlist-retired',
14
+ passed: true,
15
+ details: 'Static external benchmark watchlists are retired; use live official docs and repo evidence for current claims.',
16
+ },
17
+ ];
126
18
  const intelligenceReport = {
127
19
  generatedAt: new Date().toISOString(),
128
20
  reportName: 'benchmark-intelligence',
129
- passed: failedCheckCount === 0,
130
- failureCount: failedCheckCount,
131
- reviewSlaDays: REVIEW_SLA_DAYS,
132
- watchlist: watchlistReport,
21
+ passed: true,
22
+ failureCount: 0,
23
+ reviewSlaDays: null,
24
+ staticExternalWatchlistRetired: true,
25
+ watchlist: [],
133
26
  results: validationResults,
134
27
  };
135
28
 
@@ -152,10 +152,6 @@ function loadScenarios(reproducibilityProfile) {
152
152
  }
153
153
 
154
154
  function buildBaseSignals(detectionBenchmarkReport, tokenBenchmarkReport, benchmarkGateReport, benchmarkIntelligenceReport, thresholdConfiguration) {
155
- const staleWatchlistCount = Array.isArray(benchmarkIntelligenceReport?.watchlist)
156
- ? benchmarkIntelligenceReport.watchlist.filter((watchlistEntry) => watchlistEntry?.stale === true).length
157
- : 0;
158
-
159
155
  const top1Accuracy = Number(detectionBenchmarkReport?.top1Accuracy || 0);
160
156
  const manualCorrectionRate = Number(detectionBenchmarkReport?.manualCorrectionRate || 1);
161
157
 
@@ -166,7 +162,7 @@ function buildBaseSignals(detectionBenchmarkReport, tokenBenchmarkReport, benchm
166
162
  benchmarkGatePassed: benchmarkGateReport?.passed === true,
167
163
  benchmarkGateFailureCount: Number(benchmarkGateReport?.failureCount || 0),
168
164
  intelligenceFailureCount: Number(benchmarkIntelligenceReport?.failureCount || 0),
169
- staleWatchlistCount,
165
+ staticExternalWatchlistRetired: benchmarkIntelligenceReport?.staticExternalWatchlistRetired === true,
170
166
  top1AccuracyMet: top1Accuracy >= Number(thresholdConfiguration?.minimumTop1Accuracy || 0),
171
167
  manualCorrectionMet: manualCorrectionRate <= Number(thresholdConfiguration?.maximumManualCorrectionRate || 1),
172
168
  };
@@ -182,7 +178,7 @@ function buildWriterScenarioRun(writerModel, scenario, baseSignals, writerWeight
182
178
  ? clamp(100 + deterministicOffset(`${writerModel.id}:reliability`, 2), 0, 100)
183
179
  : clamp(100 - (baseSignals.benchmarkGateFailureCount * 20), 0, 100);
184
180
  const freshnessScore = clamp(
185
- 100 - (baseSignals.intelligenceFailureCount * 15) - (baseSignals.staleWatchlistCount * 10) + deterministicOffset(`${writerModel.id}:freshness`, 2),
181
+ 100 - (baseSignals.intelligenceFailureCount * 15) + deterministicOffset(`${writerModel.id}:freshness`, 2),
186
182
  0,
187
183
  100
188
184
  );
@@ -62,16 +62,31 @@ async function bumpVersion() {
62
62
  console.log('Updated package-lock.json');
63
63
  }
64
64
 
65
- // 3. Update docs/deep_analysis_and_roadmap_backlog.md
66
- const roadmapPath = path.join(ROOT_DIR, 'docs', 'deep_analysis_and_roadmap_backlog.md');
65
+ // 3. Update docs/deep-analysis-and-roadmap-backlog.md
66
+ const roadmapPath = path.join(ROOT_DIR, 'docs', 'deep-analysis-and-roadmap-backlog.md');
67
67
  if (await fileExists(roadmapPath)) {
68
68
  let roadmapContent = await readTextFile(roadmapPath);
69
69
  roadmapContent = roadmapContent.replace(`Current Version: ${oldVersion}`, `Current Version: ${newVersion}`);
70
70
  await writeTextFile(roadmapPath, roadmapContent);
71
- console.log('Updated docs/deep_analysis_and_roadmap_backlog.md');
71
+ console.log('Updated docs/deep-analysis-and-roadmap-backlog.md');
72
72
  }
73
73
 
74
- // 4. Update CHANGELOG.md
74
+ // 4. Update legacy root adapters that carry release metadata.
75
+ const legacyAdapterFiles = ['.cursorrules', '.windsurfrules'];
76
+ for (const legacyAdapterFile of legacyAdapterFiles) {
77
+ const legacyAdapterPath = path.join(ROOT_DIR, legacyAdapterFile);
78
+ if (await fileExists(legacyAdapterPath)) {
79
+ const legacyAdapterContent = await readTextFile(legacyAdapterPath);
80
+ const updatedLegacyAdapterContent = legacyAdapterContent.replace(
81
+ /Generated by Agentic-Senior-Core CLI v\d+\.\d+\.\d+/,
82
+ `Generated by Agentic-Senior-Core CLI v${newVersion}`
83
+ );
84
+ await writeTextFile(legacyAdapterPath, updatedLegacyAdapterContent);
85
+ console.log(`Updated ${legacyAdapterFile}`);
86
+ }
87
+ }
88
+
89
+ // 5. Update CHANGELOG.md
75
90
  const changelogPath = path.join(ROOT_DIR, 'CHANGELOG.md');
76
91
  if (await fileExists(changelogPath)) {
77
92
  let changelogContent = await readTextFile(changelogPath);
@@ -12,6 +12,7 @@ const LOCAL_ARTIFACT_PATHS = [
12
12
  'validate_output.txt',
13
13
  'release-gate-report.json',
14
14
  '.benchmarks',
15
+ '.zed',
15
16
  '.agentic-backup',
16
17
  '.agent-context/state/active-memory.json',
17
18
  '.agent-context/state/v3-purge-audit.json',
@@ -33,7 +33,7 @@ const MONITORED_STATIC_FILE_PATHS = [
33
33
  '.gemini/instructions.md',
34
34
  '.cursor/rules/agentic-senior-core.mdc',
35
35
  '.windsurf/rules/agentic-senior-core.md',
36
- 'docs/deep_analysis_and_roadmap_backlog.md',
36
+ 'docs/deep-analysis-and-roadmap-backlog.md',
37
37
  ];
38
38
 
39
39
  const MONITORED_DIRECTORY_PATHS = [
@@ -3,9 +3,9 @@
3
3
  /**
4
4
  * frontend-usability-audit.mjs
5
5
  *
6
- * Governance-level audit for V1.7 frontend execution assets.
6
+ * Governance-level audit for current frontend governance assets.
7
7
  * This repository does not host a frontend runtime app, so the audit validates
8
- * required execution artifacts and quality gates documentation.
8
+ * required quality gates and archived execution evidence.
9
9
  */
10
10
 
11
11
  import { existsSync, readFileSync } from 'node:fs';
@@ -18,8 +18,8 @@ const REPOSITORY_ROOT = resolve(__dirname, '..');
18
18
 
19
19
  const REQUIRED_FILES = [
20
20
  'docs/roadmap.md',
21
- 'docs/v1.7-issue-breakdown.md',
22
- 'docs/v1.7-execution-playbook.md',
21
+ 'docs/archive/v1.7-issue-breakdown.md',
22
+ 'docs/archive/v1.7-execution-playbook.md',
23
23
  '.instructions.md',
24
24
  '.agent-context/prompts/bootstrap-design.md',
25
25
  'scripts/ui-design-judge.mjs',
@@ -15,6 +15,10 @@ export const DEFAULT_TREND_WINDOW_DAYS = 90;
15
15
  export const MAX_TREND_PACKAGES = 10;
16
16
  export const FALLBACK_PACKAGE_VERSION = '0.0.0-local';
17
17
 
18
+ // IMPORTANT: This version extraction logic is intentionally duplicated from lib/cli/constants.mjs.
19
+ // The MCP server is designed to be copied directly into target user workspaces where
20
+ // the original package.json may not exist in the parent tree. This try/catch fallback
21
+ // ensures the server can still run standalone without crashing if package.json is missing.
18
22
  function resolvePackageVersion() {
19
23
  try {
20
24
  const parsedPackageManifest = JSON.parse(
@@ -100,7 +100,6 @@ export function runStaticReleaseChecks(results, diagnostics) {
100
100
 
101
101
  const requiredOperationsFiles = [
102
102
  '.agent-context/review-checklists/architecture-review.md',
103
- 'docs/v1.8-operations-playbook.md',
104
103
  '.github/workflows/release-gate.yml',
105
104
  '.github/workflows/sbom-compliance.yml',
106
105
  '.github/workflows/governance-weekly-report.yml',
@@ -14,7 +14,7 @@ export const FORMAL_ARTIFACT_PATHS = [
14
14
  '.instructions.md',
15
15
  'README.md',
16
16
  'CHANGELOG.md',
17
- 'docs/deep_analysis_and_roadmap_backlog.md',
17
+ 'docs/deep-analysis-and-roadmap-backlog.md',
18
18
  '.agent-context/rules/api-docs.md',
19
19
  '.agent-context/review-checklists/pr-checklist.md',
20
20
  '.agent-context/prompts/review-code.md',
@@ -49,7 +49,7 @@ export const REQUIRED_HUMAN_WRITING_SNIPPETS = [
49
49
  ],
50
50
  },
51
51
  {
52
- path: 'docs/deep_analysis_and_roadmap_backlog.md',
52
+ path: 'docs/deep-analysis-and-roadmap-backlog.md',
53
53
  snippets: [
54
54
  '## Part 6: Documentation and Explanation Standards (Mandatory)',
55
55
  'This applies to documentation, release notes, onboarding text, review summaries, and agent-facing explanations.',
@@ -166,14 +166,12 @@ async function validateRequiredFiles() {
166
166
  'docs/faq.md',
167
167
  'docs/deep-dive.md',
168
168
  'docs/terminology-mapping.md',
169
- 'docs/v1.7-execution-playbook.md',
170
- 'docs/v1.7-issue-breakdown.md',
171
- 'docs/v1.8-operations-playbook.md',
172
- 'docs/v2-upgrade-playbook.md',
169
+ 'docs/archive/v1.7-execution-playbook.md',
170
+ 'docs/archive/v1.7-issue-breakdown.md',
171
+ 'docs/archive/v1.8-operations-playbook.md',
172
+ 'docs/archive/v2-upgrade-playbook.md',
173
173
  '.agent-context/state/benchmark-reproducibility.json',
174
174
  '.agent-context/state/benchmark-writer-judge-config.json',
175
- '.agent-context/state/benchmark-watchlist.json',
176
- '.agent-context/state/stack-research-snapshot.json',
177
175
  '.agent-context/state/memory-schema-v1.json',
178
176
  '.agent-context/state/memory-adapter-contract.json',
179
177
  '.vscode/mcp.json',
@@ -569,7 +567,7 @@ async function validateDocumentationFlow() {
569
567
  'npm run validate',
570
568
  'docs/faq.md',
571
569
  'docs/deep-dive.md',
572
- 'docs/v2-upgrade-playbook.md',
570
+ 'docs/archive/v2-upgrade-playbook.md',
573
571
  ];
574
572
 
575
573
  for (const requiredReadmeSnippet of requiredReadmeSnippets) {
@@ -581,90 +579,17 @@ async function validateDocumentationFlow() {
581
579
  }
582
580
  }
583
581
 
584
- function isNormalizedMetricValue(value) {
585
- return Number.isFinite(Number(value)) && Number(value) >= 0 && Number(value) <= 1;
586
- }
587
-
588
- async function validateStackResearchSnapshotState() {
589
- console.log('\nChecking deterministic stack research snapshot state...');
590
-
591
- const snapshotPath = join(ROOT_DIR, '.agent-context', 'state', 'stack-research-snapshot.json');
592
- if (!(await fileExists(snapshotPath))) {
593
- fail('Missing deterministic stack research snapshot: .agent-context/state/stack-research-snapshot.json');
594
- return;
595
- }
596
-
597
- let snapshotPayload;
598
- try {
599
- snapshotPayload = JSON.parse(await readTextFile(snapshotPath));
600
- } catch {
601
- fail('Invalid JSON in .agent-context/state/stack-research-snapshot.json');
602
- return;
603
- }
604
-
605
- if (snapshotPayload?.deterministic === true) {
606
- pass('stack-research-snapshot.json declares deterministic: true');
607
- } else {
608
- fail('stack-research-snapshot.json must declare deterministic: true');
609
- }
610
-
611
- const generatedAtValue = String(snapshotPayload?.generatedAt || '');
612
- if (!Number.isNaN(Date.parse(generatedAtValue))) {
613
- pass('stack-research-snapshot.json includes valid generatedAt timestamp');
614
- } else {
615
- fail('stack-research-snapshot.json must include a valid generatedAt timestamp');
616
- }
617
-
618
- if (Array.isArray(snapshotPayload?.trustedRealtimeSources) && snapshotPayload.trustedRealtimeSources.length > 0) {
619
- pass('stack-research-snapshot.json includes trustedRealtimeSources');
620
- } else {
621
- fail('stack-research-snapshot.json must include at least one trustedRealtimeSources entry');
622
- }
623
-
624
- if (!Array.isArray(snapshotPayload?.stackSignals) || snapshotPayload.stackSignals.length === 0) {
625
- fail('stack-research-snapshot.json must include non-empty stackSignals array');
626
- return;
627
- }
628
-
629
- pass(`stack-research-snapshot.json includes ${snapshotPayload.stackSignals.length} stack signal entries`);
630
-
631
- const invalidSignalEntries = snapshotPayload.stackSignals.filter((signalEntry) => {
632
- const hasStackName = typeof signalEntry?.stackFileName === 'string' && signalEntry.stackFileName.trim().length > 0;
633
- const hasMeasuredAt = !Number.isNaN(Date.parse(String(signalEntry?.measuredAt || '')));
634
- const metrics = signalEntry?.metrics || {};
635
- const hasValidMetrics = isNormalizedMetricValue(metrics.ecosystemMaturity)
636
- && isNormalizedMetricValue(metrics.talentAvailability)
637
- && isNormalizedMetricValue(metrics.deliveryVelocity);
638
-
639
- return !(hasStackName && hasMeasuredAt && hasValidMetrics);
640
- });
641
-
642
- if (invalidSignalEntries.length === 0) {
643
- pass('stack-research-snapshot.json stackSignals keep measurable metrics and timestamps');
644
- } else {
645
- fail(`stack-research-snapshot.json has invalid stackSignals entries: ${invalidSignalEntries.length}`);
646
- }
647
- }
648
-
649
582
  async function validateMcpConfiguration() {
650
583
  console.log('\nChecking MCP configuration...');
651
584
 
652
585
  const mcpConfiguration = JSON.parse(await readTextFile(join(ROOT_DIR, 'mcp.json')));
653
- const lintServerCommand = mcpConfiguration.servers?.lint?.command;
654
- const testServerCommand = mcpConfiguration.servers?.test?.command;
655
586
  const workspaceMcpConfiguration = JSON.parse(await readTextFile(join(ROOT_DIR, '.vscode', 'mcp.json')));
656
587
  const workspaceServerConfig = workspaceMcpConfiguration.servers?.['agentic-senior-core'];
657
588
 
658
- if (lintServerCommand === 'node') {
659
- pass('MCP lint server uses Node');
660
- } else {
661
- fail('MCP lint server must use Node');
662
- }
663
-
664
- if (testServerCommand === 'node') {
665
- pass('MCP test server uses Node');
589
+ if (mcpConfiguration.knowledgeLayers?.enabled === true) {
590
+ pass('Root MCP config has knowledgeLayers enabled');
666
591
  } else {
667
- fail('MCP test server must use Node');
592
+ fail('Root MCP config must have knowledgeLayers.enabled: true');
668
593
  }
669
594
 
670
595
  if (typeof workspaceMcpConfiguration.$schema === 'undefined') {
@@ -732,7 +657,6 @@ async function main() {
732
657
  await validateDependencyFreshnessAutomationCoverage(coverageValidationContext);
733
658
  await validateDeterministicBoundaryEnforcementCoverage(coverageValidationContext);
734
659
  await validateRulesOnlyActiveSurfaceCoverage(coverageValidationContext);
735
- await validateStackResearchSnapshotState();
736
660
  await validateMcpConfiguration();
737
661
  await validateHumanWritingGovernance(coverageValidationContext);
738
662
  await validateInstructionAdapters(coverageValidationContext);
@@ -1,19 +0,0 @@
1
- {
2
- "repositories": [
3
- {
4
- "repository": "sickn33/antigravity-awesome-skills",
5
- "owner": "core-architecture",
6
- "lastReviewedAt": "2026-04-17"
7
- },
8
- {
9
- "repository": "github/awesome-copilot",
10
- "owner": "core-architecture",
11
- "lastReviewedAt": "2026-04-17"
12
- },
13
- {
14
- "repository": "MiniMax-AI/skills",
15
- "owner": "frontend-governance",
16
- "lastReviewedAt": "2026-04-17"
17
- }
18
- ]
19
- }
@@ -1,112 +0,0 @@
1
- {
2
- "schemaVersion": "1.0.0",
3
- "snapshotId": "ecosystem-signals-2026-04-18",
4
- "generatedAt": "2026-04-18T00:00:00.000Z",
5
- "deterministic": true,
6
- "sourceName": "Agentic-Senior-Core deterministic stack research snapshot",
7
- "sourceUrl": "state://stack-research-snapshot/2026-04-18",
8
- "trustedRealtimeSources": [
9
- {
10
- "sourceId": "awwwards-trend-feed",
11
- "sourceName": "Awwwards Trend Feed",
12
- "sourceUrl": "https://www.awwwards.com"
13
- },
14
- {
15
- "sourceId": "github-ecosystem-signals",
16
- "sourceName": "GitHub Ecosystem Signals",
17
- "sourceUrl": "https://github.com"
18
- }
19
- ],
20
- "stackSignals": [
21
- {
22
- "stackFileName": "typescript.md",
23
- "measuredAt": "2026-04-18T00:00:00.000Z",
24
- "metrics": {
25
- "ecosystemMaturity": 0.91,
26
- "talentAvailability": 0.9,
27
- "deliveryVelocity": 0.89
28
- }
29
- },
30
- {
31
- "stackFileName": "python.md",
32
- "measuredAt": "2026-04-18T00:00:00.000Z",
33
- "metrics": {
34
- "ecosystemMaturity": 0.92,
35
- "talentAvailability": 0.88,
36
- "deliveryVelocity": 0.9
37
- }
38
- },
39
- {
40
- "stackFileName": "java.md",
41
- "measuredAt": "2026-04-18T00:00:00.000Z",
42
- "metrics": {
43
- "ecosystemMaturity": 0.89,
44
- "talentAvailability": 0.83,
45
- "deliveryVelocity": 0.8
46
- }
47
- },
48
- {
49
- "stackFileName": "php.md",
50
- "measuredAt": "2026-04-18T00:00:00.000Z",
51
- "metrics": {
52
- "ecosystemMaturity": 0.79,
53
- "talentAvailability": 0.75,
54
- "deliveryVelocity": 0.84
55
- }
56
- },
57
- {
58
- "stackFileName": "go.md",
59
- "measuredAt": "2026-04-18T00:00:00.000Z",
60
- "metrics": {
61
- "ecosystemMaturity": 0.84,
62
- "talentAvailability": 0.78,
63
- "deliveryVelocity": 0.82
64
- }
65
- },
66
- {
67
- "stackFileName": "csharp.md",
68
- "measuredAt": "2026-04-18T00:00:00.000Z",
69
- "metrics": {
70
- "ecosystemMaturity": 0.86,
71
- "talentAvailability": 0.8,
72
- "deliveryVelocity": 0.79
73
- }
74
- },
75
- {
76
- "stackFileName": "rust.md",
77
- "measuredAt": "2026-04-18T00:00:00.000Z",
78
- "metrics": {
79
- "ecosystemMaturity": 0.74,
80
- "talentAvailability": 0.63,
81
- "deliveryVelocity": 0.67
82
- }
83
- },
84
- {
85
- "stackFileName": "ruby.md",
86
- "measuredAt": "2026-04-18T00:00:00.000Z",
87
- "metrics": {
88
- "ecosystemMaturity": 0.7,
89
- "talentAvailability": 0.62,
90
- "deliveryVelocity": 0.72
91
- }
92
- },
93
- {
94
- "stackFileName": "react-native.md",
95
- "measuredAt": "2026-04-18T00:00:00.000Z",
96
- "metrics": {
97
- "ecosystemMaturity": 0.72,
98
- "talentAvailability": 0.67,
99
- "deliveryVelocity": 0.74
100
- }
101
- },
102
- {
103
- "stackFileName": "flutter.md",
104
- "measuredAt": "2026-04-18T00:00:00.000Z",
105
- "metrics": {
106
- "ecosystemMaturity": 0.75,
107
- "talentAvailability": 0.69,
108
- "deliveryVelocity": 0.76
109
- }
110
- }
111
- ]
112
- }
@@ -1,54 +0,0 @@
1
- name: V1.7 Frontend Work Item
2
- description: Track a V1.7 frontend task with quality-gate ready acceptance criteria.
3
- title: "[V1.7][QX] "
4
- labels:
5
- - v1.7
6
- body:
7
- - type: textarea
8
- id: background
9
- attributes:
10
- label: Background
11
- description: Why this item exists and what user problem it addresses.
12
- validations:
13
- required: true
14
- - type: textarea
15
- id: scope
16
- attributes:
17
- label: Scope
18
- description: What is included in this issue.
19
- validations:
20
- required: true
21
- - type: textarea
22
- id: out_of_scope
23
- attributes:
24
- label: Out of Scope
25
- description: What is intentionally excluded.
26
- validations:
27
- required: true
28
- - type: textarea
29
- id: acceptance_criteria
30
- attributes:
31
- label: Acceptance Criteria
32
- description: Use measurable and testable criteria.
33
- placeholder: |
34
- - [ ] ...
35
- - [ ] ...
36
- validations:
37
- required: true
38
- - type: textarea
39
- id: dependencies
40
- attributes:
41
- label: Dependencies
42
- description: Link prerequisite issues or blockers.
43
- - type: textarea
44
- id: definition_of_done
45
- attributes:
46
- label: Definition of Done
47
- description: Include testing, documentation, and evidence requirements.
48
- validations:
49
- required: true
50
- - type: textarea
51
- id: evidence
52
- attributes:
53
- label: Evidence
54
- description: Screenshots, benchmark output, links to reports.