@ryuenn3123/agentic-senior-core 2.5.10 → 2.5.11
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/.agent-context/prompts/refactor.md +6 -0
- package/.agent-context/review-checklists/architecture-review.md +6 -0
- package/.agent-context/review-checklists/pr-checklist.md +3 -0
- package/.agent-context/rules/architecture.md +10 -0
- package/.agent-context/state/memory-continuity-benchmark.json +1 -1
- package/.cursorrules +1 -1
- package/.windsurfrules +1 -1
- package/package.json +1 -1
- package/scripts/release-gate.mjs +84 -0
|
@@ -14,12 +14,18 @@ Before making changes:
|
|
|
14
14
|
2. Read .agent-context/rules/naming-conv.md — fix all naming violations.
|
|
15
15
|
3. Read .agent-context/rules/error-handling.md — fix error handling patterns.
|
|
16
16
|
4. Read .agent-context/stacks/typescript.md — fix TypeScript-specific issues.
|
|
17
|
+
5. Enforce backend universal principles: no clever hacks, no premature abstraction, readability over brevity.
|
|
17
18
|
|
|
18
19
|
For every change you make, provide a Reasoning Chain:
|
|
19
20
|
- What was wrong (rule reference)
|
|
20
21
|
- Why it was wrong (explain the risk/problem)
|
|
21
22
|
- What you changed (show the improvement)
|
|
22
23
|
|
|
24
|
+
Refactor guidance:
|
|
25
|
+
- Prioritize maintainability over compressed one-liners.
|
|
26
|
+
- Prefer explicit readable control flow when short forms hide intent.
|
|
27
|
+
- Do not introduce shared abstractions before patterns are repeated and stable.
|
|
28
|
+
|
|
23
29
|
Maintain ALL existing functionality. This is a refactor, not a rewrite.
|
|
24
30
|
Add or update tests if the refactored code changes behavior contracts.
|
|
25
31
|
```
|
|
@@ -29,6 +29,12 @@ Evaluate every item against the current project structure. For each violation, e
|
|
|
29
29
|
- [ ] **Shared code is genuinely shared** — Not domain-specific code disguised as "common"
|
|
30
30
|
- [ ] **Module size is reasonable** — If a module has 20+ files, consider splitting
|
|
31
31
|
|
|
32
|
+
## Backend Universal Principles
|
|
33
|
+
|
|
34
|
+
- [ ] **No clever hacks in backend and shared core modules** — Prefer explicit flow over language tricks that hide intent
|
|
35
|
+
- [ ] **No premature abstraction** — Introduce shared abstractions only after repeated, stable patterns emerge
|
|
36
|
+
- [ ] **Readability over brevity** — Prefer clear multi-line logic over compressed one-liners
|
|
37
|
+
|
|
32
38
|
## Dependency Management
|
|
33
39
|
|
|
34
40
|
- [ ] **No God classes** — No class/file with 500+ lines or 10+ dependencies
|
|
@@ -40,6 +40,9 @@ VERDICT: PASS / FAIL (X/Y items passed)
|
|
|
40
40
|
- [ ] Dependencies flow inward (transport → service → repository)
|
|
41
41
|
- [ ] Module boundaries respected (no reaching into another module's internals)
|
|
42
42
|
- [ ] Domain layer has zero external dependencies
|
|
43
|
+
- [ ] No clever hacks in backend and shared core modules (prefer explicit control flow)
|
|
44
|
+
- [ ] No premature abstraction (base classes/util layers created only after repeated stable patterns)
|
|
45
|
+
- [ ] Readability over brevity for maintainability (no compressed one-liners that hide intent)
|
|
43
46
|
|
|
44
47
|
### 3. Type Safety (→ stacks/typescript.md)
|
|
45
48
|
- [ ] No `any` type anywhere (use `unknown` + narrowing)
|
|
@@ -3,6 +3,16 @@
|
|
|
3
3
|
> If your service file imports an HTTP library, your architecture is broken.
|
|
4
4
|
> If your controller contains SQL, you've already lost.
|
|
5
5
|
|
|
6
|
+
## Universal Backend Principles (Mandatory)
|
|
7
|
+
|
|
8
|
+
These principles are mandatory for backend and shared core modules.
|
|
9
|
+
|
|
10
|
+
- No clever hacks. Prefer explicit control flow over language tricks that hide intent.
|
|
11
|
+
- No premature abstraction. Extract shared utilities or base types only after repeated, stable patterns appear.
|
|
12
|
+
- Readability over brevity. Reject compressed one-liners when clearer multi-line logic is easier to review.
|
|
13
|
+
|
|
14
|
+
If a short and a clear implementation are functionally equivalent, choose the clear implementation.
|
|
15
|
+
|
|
6
16
|
## The Core Principle
|
|
7
17
|
|
|
8
18
|
**Every layer has ONE job. Layer leaks are bugs — not "pragmatic shortcuts."**
|
package/.cursorrules
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# AGENTIC-SENIOR-CORE DYNAMIC GOVERNANCE RULESET
|
|
2
2
|
|
|
3
|
-
Generated by Agentic-Senior-Core CLI v2.5.
|
|
3
|
+
Generated by Agentic-Senior-Core CLI v2.5.11
|
|
4
4
|
Timestamp: 2026-04-15T00:14:51.184Z
|
|
5
5
|
Selected profile: beginner
|
|
6
6
|
Selected policy file: .agent-context/policies/llm-judge-threshold.json
|
package/.windsurfrules
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# AGENTIC-SENIOR-CORE DYNAMIC GOVERNANCE RULESET
|
|
2
2
|
|
|
3
|
-
Generated by Agentic-Senior-Core CLI v2.5.
|
|
3
|
+
Generated by Agentic-Senior-Core CLI v2.5.11
|
|
4
4
|
Timestamp: 2026-04-15T00:14:51.184Z
|
|
5
5
|
Selected profile: beginner
|
|
6
6
|
Selected policy file: .agent-context/policies/llm-judge-threshold.json
|
package/package.json
CHANGED
package/scripts/release-gate.mjs
CHANGED
|
@@ -30,6 +30,9 @@ const REQUIRED_SKILL_DOMAINS = [
|
|
|
30
30
|
const FRONTEND_PARITY_CHECKLIST_PATH = '.agent-context/review-checklists/frontend-skill-parity.md';
|
|
31
31
|
const FRONTEND_EXCELLENCE_RUBRIC_PATH = '.agent-context/review-checklists/frontend-excellence-rubric.md';
|
|
32
32
|
const FRONTEND_AUDIT_SCRIPT_PATH = 'scripts/frontend-usability-audit.mjs';
|
|
33
|
+
const BACKEND_ARCHITECTURE_RULE_PATH = '.agent-context/rules/architecture.md';
|
|
34
|
+
const BACKEND_REVIEW_CHECKLIST_PATH = '.agent-context/review-checklists/pr-checklist.md';
|
|
35
|
+
const REFACTOR_PROMPT_PATH = '.agent-context/prompts/refactor.md';
|
|
33
36
|
const REQUIRED_FRONTEND_PARITY_SNIPPETS = [
|
|
34
37
|
'Architecture and Composition',
|
|
35
38
|
'Interaction and Motion',
|
|
@@ -37,6 +40,21 @@ const REQUIRED_FRONTEND_PARITY_SNIPPETS = [
|
|
|
37
40
|
'UX Narrative and Conversion Clarity',
|
|
38
41
|
'Release Evidence',
|
|
39
42
|
];
|
|
43
|
+
const REQUIRED_BACKEND_ARCHITECTURE_RULE_SNIPPETS = [
|
|
44
|
+
'No clever hacks.',
|
|
45
|
+
'No premature abstraction.',
|
|
46
|
+
'Readability over brevity.',
|
|
47
|
+
'backend and shared core modules',
|
|
48
|
+
];
|
|
49
|
+
const REQUIRED_BACKEND_REVIEW_CHECKLIST_SNIPPETS = [
|
|
50
|
+
'No clever hacks in backend and shared core modules',
|
|
51
|
+
'No premature abstraction (base classes/util layers created only after repeated stable patterns)',
|
|
52
|
+
'Readability over brevity for maintainability',
|
|
53
|
+
];
|
|
54
|
+
const REQUIRED_REFACTOR_PROMPT_SNIPPETS = [
|
|
55
|
+
'Enforce backend universal principles: no clever hacks, no premature abstraction, readability over brevity.',
|
|
56
|
+
'Prioritize maintainability over compressed one-liners.',
|
|
57
|
+
];
|
|
40
58
|
const REQUIRED_FRONTEND_EXCELLENCE_RUBRIC_SNIPPETS = [
|
|
41
59
|
'Visual Direction and Identity',
|
|
42
60
|
'Typography Quality',
|
|
@@ -253,6 +271,72 @@ function runReleaseGate() {
|
|
|
253
271
|
);
|
|
254
272
|
}
|
|
255
273
|
|
|
274
|
+
const backendArchitectureRuleContent = readText(BACKEND_ARCHITECTURE_RULE_PATH);
|
|
275
|
+
if (!backendArchitectureRuleContent) {
|
|
276
|
+
pushResult(results, false, 'backend-universal-principles-rule-exists', `Missing ${BACKEND_ARCHITECTURE_RULE_PATH}`);
|
|
277
|
+
} else {
|
|
278
|
+
pushResult(results, true, 'backend-universal-principles-rule-exists', `${BACKEND_ARCHITECTURE_RULE_PATH} is present`);
|
|
279
|
+
|
|
280
|
+
const missingBackendArchitectureRuleSnippets = REQUIRED_BACKEND_ARCHITECTURE_RULE_SNIPPETS.filter(
|
|
281
|
+
(requiredSnippet) => !backendArchitectureRuleContent.includes(requiredSnippet)
|
|
282
|
+
);
|
|
283
|
+
|
|
284
|
+
if (missingBackendArchitectureRuleSnippets.length === 0) {
|
|
285
|
+
pushResult(results, true, 'backend-universal-principles-rule-coverage', 'Backend universal rule snippets are complete');
|
|
286
|
+
} else {
|
|
287
|
+
pushResult(
|
|
288
|
+
results,
|
|
289
|
+
false,
|
|
290
|
+
'backend-universal-principles-rule-coverage',
|
|
291
|
+
`Missing backend universal rule snippets: ${missingBackendArchitectureRuleSnippets.join(', ')}`
|
|
292
|
+
);
|
|
293
|
+
}
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
const backendReviewChecklistContent = readText(BACKEND_REVIEW_CHECKLIST_PATH);
|
|
297
|
+
if (!backendReviewChecklistContent) {
|
|
298
|
+
pushResult(results, false, 'backend-universal-principles-checklist-exists', `Missing ${BACKEND_REVIEW_CHECKLIST_PATH}`);
|
|
299
|
+
} else {
|
|
300
|
+
pushResult(results, true, 'backend-universal-principles-checklist-exists', `${BACKEND_REVIEW_CHECKLIST_PATH} is present`);
|
|
301
|
+
|
|
302
|
+
const missingBackendChecklistSnippets = REQUIRED_BACKEND_REVIEW_CHECKLIST_SNIPPETS.filter(
|
|
303
|
+
(requiredSnippet) => !backendReviewChecklistContent.includes(requiredSnippet)
|
|
304
|
+
);
|
|
305
|
+
|
|
306
|
+
if (missingBackendChecklistSnippets.length === 0) {
|
|
307
|
+
pushResult(results, true, 'backend-universal-principles-checklist-coverage', 'Backend review checklist snippets are complete');
|
|
308
|
+
} else {
|
|
309
|
+
pushResult(
|
|
310
|
+
results,
|
|
311
|
+
false,
|
|
312
|
+
'backend-universal-principles-checklist-coverage',
|
|
313
|
+
`Missing backend review checklist snippets: ${missingBackendChecklistSnippets.join(', ')}`
|
|
314
|
+
);
|
|
315
|
+
}
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
const refactorPromptContent = readText(REFACTOR_PROMPT_PATH);
|
|
319
|
+
if (!refactorPromptContent) {
|
|
320
|
+
pushResult(results, false, 'backend-universal-principles-refactor-guidance-exists', `Missing ${REFACTOR_PROMPT_PATH}`);
|
|
321
|
+
} else {
|
|
322
|
+
pushResult(results, true, 'backend-universal-principles-refactor-guidance-exists', `${REFACTOR_PROMPT_PATH} is present`);
|
|
323
|
+
|
|
324
|
+
const missingRefactorPromptSnippets = REQUIRED_REFACTOR_PROMPT_SNIPPETS.filter(
|
|
325
|
+
(requiredSnippet) => !refactorPromptContent.includes(requiredSnippet)
|
|
326
|
+
);
|
|
327
|
+
|
|
328
|
+
if (missingRefactorPromptSnippets.length === 0) {
|
|
329
|
+
pushResult(results, true, 'backend-universal-principles-refactor-guidance-coverage', 'Backend refactor guidance snippets are complete');
|
|
330
|
+
} else {
|
|
331
|
+
pushResult(
|
|
332
|
+
results,
|
|
333
|
+
false,
|
|
334
|
+
'backend-universal-principles-refactor-guidance-coverage',
|
|
335
|
+
`Missing backend refactor guidance snippets: ${missingRefactorPromptSnippets.join(', ')}`
|
|
336
|
+
);
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
|
|
256
340
|
const frontendParityChecklistContent = readText(FRONTEND_PARITY_CHECKLIST_PATH);
|
|
257
341
|
if (!frontendParityChecklistContent) {
|
|
258
342
|
pushResult(results, false, 'frontend-parity-checklist-exists', `Missing ${FRONTEND_PARITY_CHECKLIST_PATH}`);
|