agent-enderun 0.7.1 → 0.7.5
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/.enderun/BRAIN_DASHBOARD.md +47 -0
- package/.enderun/PROJECT_MEMORY.md +139 -0
- package/.enderun/STATUS.md +62 -0
- package/.enderun/agents/agent_army_schema.json +85 -0
- package/.enderun/agents/analyst/agent.json +23 -0
- package/.enderun/agents/analyst/prompt.md +225 -0
- package/.enderun/agents/backend/agent.json +24 -0
- package/.enderun/agents/backend/prompt.md +331 -0
- package/.enderun/agents/devops/agent.json +61 -0
- package/.enderun/agents/devops/prompt.md +127 -0
- package/.enderun/agents/explorer/agent.json +22 -0
- package/.enderun/agents/explorer/prompt.md +115 -0
- package/.enderun/agents/frontend/agent.json +24 -0
- package/.enderun/agents/frontend/prompt.md +313 -0
- package/.enderun/agents/git/agent.json +22 -0
- package/.enderun/agents/git/prompt.md +99 -0
- package/.enderun/agents/manager/agent.json +48 -0
- package/.enderun/agents/manager/prompt.md +231 -0
- package/.enderun/agents/mobile/agent.json +21 -0
- package/.enderun/agents/mobile/prompt.md +91 -0
- package/.enderun/agents/native/agent.json +21 -0
- package/.enderun/agents/native/prompt.md +96 -0
- package/.enderun/agents/orchestrator/agent.json +53 -0
- package/.enderun/agents/orchestrator/prompt.md +124 -0
- package/.enderun/agents/qa/agent.json +57 -0
- package/.enderun/agents/qa/prompt.md +69 -0
- package/.enderun/agents/schema/agent-lifecycle-schema.json +65 -0
- package/.enderun/agents/security/agent.json +54 -0
- package/.enderun/agents/security/prompt.md +154 -0
- package/.enderun/gemini.md +19 -0
- package/.enderun/knowledge/corporate-governance/analyst-contract-integrity-guide.md +92 -0
- package/.enderun/knowledge/corporate-governance/audit-logging-standard.md +59 -0
- package/.enderun/knowledge/corporate-governance/backend-high-risk-endpoint-guide.md +125 -0
- package/.enderun/knowledge/corporate-governance/branded-types-law.md +77 -0
- package/.enderun/knowledge/corporate-governance/contract-drift-detection-simulation.md +92 -0
- package/.enderun/knowledge/corporate-governance/corporate-governance-playbook.md +89 -0
- package/.enderun/knowledge/corporate-governance/corporate-project-kickoff-checklist.md +56 -0
- package/.enderun/knowledge/corporate-governance/corporate-project-kickoff-simulation.md +144 -0
- package/.enderun/knowledge/corporate-governance/corporate-project-scaffolding-sop.md +103 -0
- package/.enderun/knowledge/corporate-governance/domain-error-handling-standard.md +75 -0
- package/.enderun/knowledge/corporate-governance/frontend-high-risk-modal-guide.md +211 -0
- package/.enderun/knowledge/corporate-governance/governance-baseline-briefing-template.md +54 -0
- package/.enderun/knowledge/corporate-governance/high-risk-action-approval-flow-simulation.md +167 -0
- package/.enderun/knowledge/corporate-governance/high-risk-actions-managerapproval.md +76 -0
- package/.enderun/knowledge/corporate-governance/high-risk-security-modal-hermes-flow.md +49 -0
- package/.enderun/knowledge/corporate-governance/manager-first-30-days-guide.md +112 -0
- package/.enderun/knowledge/corporate-governance/manager-first-three-briefings.md +79 -0
- package/.enderun/knowledge/deployment_checklist.md +7 -0
- package/{.antigravitycli → .enderun}/knowledge/framework_vs_user_project_boundary.md +3 -3
- package/{.antigravitycli → .enderun}/knowledge/frontend_professionalization_guidelines.md +17 -20
- package/{.antigravitycli → .enderun}/knowledge/hermes_live_test_guidelines.md +9 -9
- package/{.antigravitycli → .enderun}/knowledge/hermes_protocol.md +2 -2
- package/.enderun/knowledge/kentim_constitution.md +34 -0
- package/{.antigravitycli → .enderun}/knowledge/manager_authority_audit_enforcement.md +11 -11
- package/{.antigravitycli → .enderun}/knowledge/project_scaffold_guidelines.md +8 -8
- package/{.antigravitycli → .enderun}/knowledge/reference_application_guidelines.md +7 -7
- package/.enderun/logs/analyst.json +1 -0
- package/.enderun/logs/backend.json +1 -0
- package/.enderun/logs/devops.json +1 -0
- package/.enderun/logs/explorer.json +1 -0
- package/.enderun/logs/frontend.json +1 -0
- package/.enderun/logs/git.json +1 -0
- package/.enderun/logs/manager.json +20 -0
- package/.enderun/logs/mobile.json +1 -0
- package/.enderun/logs/native.json +1 -0
- package/.enderun/logs/orchestrator.json +1 -0
- package/.enderun/logs/qa.json +1 -0
- package/.enderun/logs/security.json +1 -0
- package/.enderun/memory-graph/agent-contexts/analyst.json +1 -0
- package/.enderun/memory-graph/agent-contexts/backend.json +1 -0
- package/.enderun/memory-graph/agent-contexts/devops.json +1 -0
- package/.enderun/memory-graph/agent-contexts/explorer.json +1 -0
- package/.enderun/memory-graph/agent-contexts/frontend.json +1 -0
- package/.enderun/memory-graph/agent-contexts/git.json +1 -0
- package/.enderun/memory-graph/agent-contexts/manager.json +1 -0
- package/.enderun/memory-graph/agent-contexts/mobile.json +1 -0
- package/.enderun/memory-graph/agent-contexts/native.json +1 -0
- package/.enderun/memory-graph/agent-contexts/orchestrator.json +1 -0
- package/.enderun/memory-graph/agent-contexts/qa.json +1 -0
- package/.enderun/memory-graph/agent-contexts/security.json +1 -0
- package/.enderun/memory-graph/graph.json +26 -0
- package/.enderun/memory-graph/shared-facts.json +52 -0
- package/.enderun/monitoring/.gitkeep +0 -0
- package/.enderun/queue/README.md +36 -0
- package/ENDERUN.md +4 -4
- package/README.md +151 -89
- package/bin/cli.js +13 -2138
- package/bin/hermes-sandbox.js +0 -0
- package/bin/validate-agent-army.js +3 -3
- package/docs/architecture/approval-flows.md +2 -37
- package/docs/backend/error-handling.md +2 -51
- package/docs/frontend/component-patterns.md +2 -47
- package/docs/getting-started.md +7 -15
- package/docs/roadmap.md +2 -2
- package/framework-mcp/dist/index.js +0 -0
- package/framework-mcp/dist/schemas.js +3 -3
- package/framework-mcp/dist/tools/framework.js +17 -10
- package/framework-mcp/dist/tools/governance.js +696 -0
- package/framework-mcp/dist/tools/index.js +14 -12
- package/framework-mcp/dist/tools/memory.js +106 -0
- package/framework-mcp/dist/tools/monitoring.js +294 -0
- package/framework-mcp/dist/tools/orchestration.js +368 -0
- package/framework-mcp/dist/tools/pipeline.js +267 -0
- package/framework-mcp/dist/utils.js +25 -3
- package/framework-mcp/package.json +3 -3
- package/framework-mcp/src/schemas.ts +3 -3
- package/framework-mcp/src/tools/framework.ts +18 -10
- package/framework-mcp/src/tools/governance.ts +891 -0
- package/framework-mcp/src/tools/index.ts +14 -12
- package/framework-mcp/src/tools/memory.ts +103 -0
- package/framework-mcp/src/tools/monitoring.ts +351 -0
- package/framework-mcp/src/tools/orchestration.ts +439 -0
- package/framework-mcp/src/tools/pipeline.ts +353 -0
- package/framework-mcp/src/utils.ts +24 -3
- package/framework-mcp/tsconfig.json +2 -1
- package/gemini.md +19 -0
- package/package.json +14 -20
- package/.antigravitycli/BRAIN_DASHBOARD.md +0 -43
- package/.antigravitycli/ENDERUN.md +0 -253
- package/.antigravitycli/PROJECT_MEMORY.md +0 -78
- package/.antigravitycli/STATUS.md +0 -21
- package/.antigravitycli/agents/agent_army_schema.json +0 -79
- package/.antigravitycli/agents/analyst/agent.json +0 -55
- package/.antigravitycli/agents/backend/agent.json +0 -58
- package/.antigravitycli/agents/explorer/agent.json +0 -50
- package/.antigravitycli/agents/frontend/agent.json +0 -56
- package/.antigravitycli/agents/git/agent.json +0 -53
- package/.antigravitycli/agents/manager/agent.json +0 -82
- package/.antigravitycli/agents/mobile/agent.json +0 -52
- package/.antigravitycli/agents/native/agent.json +0 -56
- package/.antigravitycli/assets/manager.png +0 -0
- package/.antigravitycli/blueprints/README.md +0 -82
- package/.antigravitycli/blueprints/backend/errors/config/meta.json +0 -16
- package/.antigravitycli/blueprints/backend/errors/domain-error.ts +0 -64
- package/.antigravitycli/knowledge/README.md +0 -22
- package/.antigravitycli/knowledge/database_governance_guidelines.md +0 -118
- package/.antigravitycli/knowledge/deployment_checklist.md +0 -133
- package/.antigravitycli/knowledge/documentation_ownership.md +0 -122
- package/.antigravitycli/knowledge/documentation_ownership_status.md +0 -122
- package/.antigravitycli/knowledge/enterprise_capabilities_reference.md +0 -149
- package/.antigravitycli/knowledge/enterprise_frontend_adaptation.md +0 -232
- package/.antigravitycli/knowledge/enterprise_project_adaptation.md +0 -168
- package/.antigravitycli/knowledge/frontend_real_battle_test_protocol.md +0 -162
- package/antigravity.md +0 -15
- package/docs/architecture/decisions/README.md +0 -31
- package/docs/architecture/notification-strategy.md +0 -38
- package/docs/backend/audit-logging.md +0 -34
- package/docs/frontend/forms.md +0 -40
- package/docs/frontend/notifications.md +0 -37
- package/framework-mcp/dist/tools/academy.js +0 -182
- package/framework-mcp/dist/tools/database.js +0 -57
- package/framework-mcp/dist/tools/repository.js +0 -101
- package/framework-mcp/dist/tools/scaffold.js +0 -132
- package/framework-mcp/src/tools/academy.ts +0 -180
- package/framework-mcp/src/tools/database.ts +0 -54
- package/framework-mcp/src/tools/repository.ts +0 -101
- package/framework-mcp/src/tools/scaffold.ts +0 -150
- /package/{.antigravitycli/messages → .enderun/benchmarks}/.gitkeep +0 -0
- /package/{.antigravitycli → .enderun}/cli-commands.json +0 -0
- /package/{.antigravitycli → .enderun}/config.json +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/api_design_rules.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/async_error_handling.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/blueprint_driven_construction.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/branded_types_pattern.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/code_review_checklist.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/contract_versioning.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/database_migration.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/git_commit_strategy.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/legacy_onboarding.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/monitoring_setup.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/performance_guidelines.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/repository_patterns.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/responsive_design_standards.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/security_scanning.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/testing_standards.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/troubleshooting_guide.md +0 -0
- /package/{.antigravitycli → .enderun}/knowledge/zero_ui_library_policy.md +0 -0
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"id": "git",
|
|
3
|
-
"name": "Git Specialist (Branch & Sync)",
|
|
4
|
-
"role": "Git Flow Orchestrator",
|
|
5
|
-
"avatar": ".antigravitycli/assets/git.png",
|
|
6
|
-
"description": "Specialist agent dedicated to git branch hygiene, git flow, commit message generation, and clean conflict resolution.",
|
|
7
|
-
"category": "DevOps & VCS",
|
|
8
|
-
"capabilityRating": "9.1",
|
|
9
|
-
"allowDirectInvocation": true,
|
|
10
|
-
"mcpServers": [
|
|
11
|
-
"agent-enderun"
|
|
12
|
-
],
|
|
13
|
-
"coreRules": [
|
|
14
|
-
"Format all git branches semantically (e.g., feat/[trace-id]-name, fix/[trace-id]-name).",
|
|
15
|
-
"Analyze staged git diffs to generate precise, structured semantic commit messages.",
|
|
16
|
-
"Resolve merge conflicts systematically, ensuring builds pass before final commit.",
|
|
17
|
-
"Enforce workspace boundaries, staging only tracked, non-ignored files."
|
|
18
|
-
],
|
|
19
|
-
"governance": {
|
|
20
|
-
"crudPolicy": "Orchestrate version control. Keep repository history linear, clean, and fully traced.",
|
|
21
|
-
"highRiskOperations": [
|
|
22
|
-
"emergency repository branch force push",
|
|
23
|
-
"git reset --hard on active working trees"
|
|
24
|
-
],
|
|
25
|
-
"approvalWorkflow": "Requires direct authorization and confirmation logs."
|
|
26
|
-
},
|
|
27
|
-
"phaseChecklists": {
|
|
28
|
-
"PHASE_1": [
|
|
29
|
-
"Configure commit hooks correctly.",
|
|
30
|
-
"Verify .gitignore coverage."
|
|
31
|
-
],
|
|
32
|
-
"PHASE_2": [
|
|
33
|
-
"Generate trace-specific feature branches.",
|
|
34
|
-
"Auto-commit checked artifacts."
|
|
35
|
-
]
|
|
36
|
-
},
|
|
37
|
-
"redLines": [
|
|
38
|
-
"Executing force push (git push --force) on main or master branch.",
|
|
39
|
-
"Writing or modifying application source files (strictly a VCS controller).",
|
|
40
|
-
"Committing node_modules, build artifacts, or secret env credentials.",
|
|
41
|
-
"Running git commands with unverified working tree statuses."
|
|
42
|
-
],
|
|
43
|
-
"permissions": {
|
|
44
|
-
"allowHighRiskOperations": true,
|
|
45
|
-
"allowedFolders": [
|
|
46
|
-
".git",
|
|
47
|
-
".antigravitycli/logs"
|
|
48
|
-
]
|
|
49
|
-
},
|
|
50
|
-
"hermesInbox": ".antigravitycli/messages/git.json",
|
|
51
|
-
"hermesOutbox": ".antigravitycli/messages/manager.json",
|
|
52
|
-
"allowedDelegations": []
|
|
53
|
-
}
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"id": "manager",
|
|
3
|
-
"name": "Manager (CTO & Controller)",
|
|
4
|
-
"role": "CTO & Controller",
|
|
5
|
-
"avatar": ".antigravitycli/assets/manager.png",
|
|
6
|
-
"description": "Lead orchestrator, process coordinator, and controller. Manages Trace IDs, inter-agent briefs, database migrations, and constitutional quality gates.",
|
|
7
|
-
"category": "Orchestration & Governance",
|
|
8
|
-
"capabilityRating": "9.5",
|
|
9
|
-
"allowDirectInvocation": true,
|
|
10
|
-
"mcpServers": [
|
|
11
|
-
"agent-enderun"
|
|
12
|
-
],
|
|
13
|
-
"coreRules": [
|
|
14
|
-
"Serve as the permanent Team-Lead (CTO & Controller) and unbreakable single point of entry in enterprise projects.",
|
|
15
|
-
"Intercept every user request first; no specialist agent may respond or start working without an official briefing.",
|
|
16
|
-
"Perform thorough intent analysis, technical debt checking, and risk assessment before task distribution.",
|
|
17
|
-
"Strictly enforce memory discipline, automatically updating PROJECT_MEMORY.md and manager.json logs at the end of every session.",
|
|
18
|
-
"Verify framework boundaries, stopping agents from writing user project code inside framework engine internals."
|
|
19
|
-
],
|
|
20
|
-
"governance": {
|
|
21
|
-
"crudPolicy": "Centralized governance. Standard CRUD is delegated via briefs, whereas high-risk administrative operations require explicit prior approval.",
|
|
22
|
-
"highRiskOperations": [
|
|
23
|
-
"User & permission suspending/role updates",
|
|
24
|
-
"Bulk database deletion or production purging",
|
|
25
|
-
"System environment variables & cache flushing",
|
|
26
|
-
"Production migrations and index creation",
|
|
27
|
-
"SSO, payment providers & identity integrations"
|
|
28
|
-
],
|
|
29
|
-
"approvalWorkflow": "Generate and inject a signed managerApproval payload containing traceId, timestamp, riskLevel, and rollbackPlan to authorizing specialist."
|
|
30
|
-
},
|
|
31
|
-
"phaseChecklists": {
|
|
32
|
-
"PHASE_0": [
|
|
33
|
-
"tech-stack.md approved.",
|
|
34
|
-
"Root docs/ requirements analyzed.",
|
|
35
|
-
"Execution Profile selected."
|
|
36
|
-
],
|
|
37
|
-
"PHASE_1": [
|
|
38
|
-
"shared-types approved.",
|
|
39
|
-
"contract.version.json created and hash verified.",
|
|
40
|
-
"OpenAPI schema documented under .antigravitycli/docs/api/."
|
|
41
|
-
],
|
|
42
|
-
"PHASE_2": [
|
|
43
|
-
"Core features delivered with unit tests.",
|
|
44
|
-
"Procedural Continuity verified across all modified files.",
|
|
45
|
-
"Log schema applied for all active agents."
|
|
46
|
-
],
|
|
47
|
-
"PHASE_3": [
|
|
48
|
-
"Integration tests passed with real DB.",
|
|
49
|
-
"Zero Mock Policy verified.",
|
|
50
|
-
"Zero UI Library Policy verified."
|
|
51
|
-
],
|
|
52
|
-
"PHASE_4": [
|
|
53
|
-
"PROJECT_MEMORY.md fully updated.",
|
|
54
|
-
"Walkthrough documentation ready."
|
|
55
|
-
]
|
|
56
|
-
},
|
|
57
|
-
"redLines": [
|
|
58
|
-
"Allowing any specialist agent to respond to the user without a manager briefing.",
|
|
59
|
-
"Distributing tasks without a Trace ID (ULID).",
|
|
60
|
-
"Deviating from existing codebase patterns (Procedural Continuity violation).",
|
|
61
|
-
"Allowing high-risk administrative CRUD without explicit managerApproval signature payload.",
|
|
62
|
-
"Allowing creation of premature shared UI packages under packages/ or shared/."
|
|
63
|
-
],
|
|
64
|
-
"permissions": {
|
|
65
|
-
"allowHighRiskOperations": true,
|
|
66
|
-
"allowedFolders": [
|
|
67
|
-
".antigravitycli",
|
|
68
|
-
"framework-mcp",
|
|
69
|
-
"bin",
|
|
70
|
-
"tests"
|
|
71
|
-
]
|
|
72
|
-
},
|
|
73
|
-
"hermesInbox": ".antigravitycli/messages/manager.json",
|
|
74
|
-
"hermesOutbox": ".antigravitycli/messages/backend.json",
|
|
75
|
-
"allowedDelegations": [
|
|
76
|
-
"backend",
|
|
77
|
-
"frontend",
|
|
78
|
-
"explorer",
|
|
79
|
-
"analyst",
|
|
80
|
-
"git"
|
|
81
|
-
]
|
|
82
|
-
}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"id": "mobile",
|
|
3
|
-
"name": "Mobile Engineer (React Native & Expo)",
|
|
4
|
-
"role": "Senior Mobile Developer",
|
|
5
|
-
"avatar": ".antigravitycli/assets/mobile.png",
|
|
6
|
-
"description": "Mobile application expert specializing in React Native, Expo development, fast app bundles, and cross-platform native hooks.",
|
|
7
|
-
"category": "Mobile Development",
|
|
8
|
-
"capabilityRating": "8.8",
|
|
9
|
-
"allowDirectInvocation": true,
|
|
10
|
-
"mcpServers": [
|
|
11
|
-
"agent-enderun"
|
|
12
|
-
],
|
|
13
|
-
"coreRules": [
|
|
14
|
-
"Build modular Expo / React Native UI interfaces adhering to fast rendering guidelines.",
|
|
15
|
-
"Implement fluid viewport calculations, verifying layouts look premium on tablets and small screens.",
|
|
16
|
-
"Structure navigation safely using Expo Router nested layouts.",
|
|
17
|
-
"Optimize bundle size, keeping native packages aligned with Expo Go compatibility."
|
|
18
|
-
],
|
|
19
|
-
"governance": {
|
|
20
|
-
"crudPolicy": "Manage mobile frontend views, state sync, local caching, and deep link endpoints.",
|
|
21
|
-
"highRiskOperations": [],
|
|
22
|
-
"approvalWorkflow": "All integrations go through analyst PR compliance checks."
|
|
23
|
-
},
|
|
24
|
-
"phaseChecklists": {
|
|
25
|
-
"PHASE_1": [
|
|
26
|
-
"Verify layout scalability on simulator viewport sizes.",
|
|
27
|
-
"Check Expo asset bundling configurations."
|
|
28
|
-
],
|
|
29
|
-
"PHASE_2": [
|
|
30
|
-
"Deliver modular screens with local mock data.",
|
|
31
|
-
"Audit navigation performance index."
|
|
32
|
-
]
|
|
33
|
-
},
|
|
34
|
-
"redLines": [
|
|
35
|
-
"Hardcoding absolute layouts without safe-area-insets.",
|
|
36
|
-
"Importing bulky and unverified native pods that break Expo builds.",
|
|
37
|
-
"Ignoring android back-button hardware overrides in modally presented screens.",
|
|
38
|
-
"Leaving large assets uncompressed in mobile bundles."
|
|
39
|
-
],
|
|
40
|
-
"permissions": {
|
|
41
|
-
"allowHighRiskOperations": false,
|
|
42
|
-
"allowedFolders": [
|
|
43
|
-
"apps/mobile",
|
|
44
|
-
"framework-mcp"
|
|
45
|
-
]
|
|
46
|
-
},
|
|
47
|
-
"hermesInbox": ".antigravitycli/messages/mobile.json",
|
|
48
|
-
"hermesOutbox": ".antigravitycli/messages/analyst.json",
|
|
49
|
-
"allowedDelegations": [
|
|
50
|
-
"analyst"
|
|
51
|
-
]
|
|
52
|
-
}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"id": "native",
|
|
3
|
-
"name": "Native Specialist (Swift & Kotlin)",
|
|
4
|
-
"role": "Senior Native Engineer",
|
|
5
|
-
"avatar": ".antigravitycli/assets/native.png",
|
|
6
|
-
"description": "Platform-native software engineer. Focuses on custom iOS (Swift/SwiftUI) and Android (Kotlin/Compose) bridges, widgets, and background performance.",
|
|
7
|
-
"category": "Native Development",
|
|
8
|
-
"capabilityRating": "8.9",
|
|
9
|
-
"allowDirectInvocation": true,
|
|
10
|
-
"mcpServers": [
|
|
11
|
-
"agent-enderun"
|
|
12
|
-
],
|
|
13
|
-
"coreRules": [
|
|
14
|
-
"Write clean SwiftUI and Kotlin Jetpack Compose views aligned with platform HIG.",
|
|
15
|
-
"Develop robust native bridges (JSI/TurboModules), declaring clean TypeScript type interfaces.",
|
|
16
|
-
"Optimize hardware access (Biometrics, secure enclave, Bluetooth) with strict background permissions.",
|
|
17
|
-
"Verify thread safety on all async bridge calls to prevent main-thread blockages."
|
|
18
|
-
],
|
|
19
|
-
"governance": {
|
|
20
|
-
"crudPolicy": "Manage secure Keychain storage, iOS/Android background sync services, and bridge calls.",
|
|
21
|
-
"highRiskOperations": [
|
|
22
|
-
"Accessing secure enclave encryption keys",
|
|
23
|
-
"Updating dynamic background sync worker schedules"
|
|
24
|
-
],
|
|
25
|
-
"approvalWorkflow": "All native bridge modifications require a dynamic managerApproval signature."
|
|
26
|
-
},
|
|
27
|
-
"phaseChecklists": {
|
|
28
|
-
"PHASE_1": [
|
|
29
|
-
"Define Swift and Kotlin package dependency trees.",
|
|
30
|
-
"Check native build tools version alignment."
|
|
31
|
-
],
|
|
32
|
-
"PHASE_2": [
|
|
33
|
-
"Expose clean JSI native interfaces.",
|
|
34
|
-
"Profile native memory footprints under load."
|
|
35
|
-
]
|
|
36
|
-
},
|
|
37
|
-
"redLines": [
|
|
38
|
-
"Creating native bridge calls that block the main UI thread.",
|
|
39
|
-
"Writing custom Swift or Kotlin bridges with unmanaged memory leaks.",
|
|
40
|
-
"Using raw pointer manipulations outside verified safe blocks.",
|
|
41
|
-
"Leaving native exceptions unhandled (which crash the host application)."
|
|
42
|
-
],
|
|
43
|
-
"permissions": {
|
|
44
|
-
"allowHighRiskOperations": true,
|
|
45
|
-
"allowedFolders": [
|
|
46
|
-
"apps/ios",
|
|
47
|
-
"apps/android",
|
|
48
|
-
"framework-mcp"
|
|
49
|
-
]
|
|
50
|
-
},
|
|
51
|
-
"hermesInbox": ".antigravitycli/messages/native.json",
|
|
52
|
-
"hermesOutbox": ".antigravitycli/messages/analyst.json",
|
|
53
|
-
"allowedDelegations": [
|
|
54
|
-
"analyst"
|
|
55
|
-
]
|
|
56
|
-
}
|
|
Binary file
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
# Blueprints
|
|
2
|
-
|
|
3
|
-
This directory stores **Gold Standard** reusable patterns and architectural capabilities for Agent Enderun.
|
|
4
|
-
|
|
5
|
-
## Purpose
|
|
6
|
-
|
|
7
|
-
Blueprints allow agents to store and reuse high-quality, repeatable architectural patterns, error systems, UI components, or business logic structures.
|
|
8
|
-
|
|
9
|
-
Goals:
|
|
10
|
-
- Standardize recurring high-quality solutions
|
|
11
|
-
- Enable agents to work from proven patterns instead of starting from scratch
|
|
12
|
-
- Raise quality at the framework level, not just per-project
|
|
13
|
-
|
|
14
|
-
## How It Works
|
|
15
|
-
|
|
16
|
-
Agents use the following tools to work with blueprints:
|
|
17
|
-
|
|
18
|
-
- `list_blueprints` → Lists all available blueprints
|
|
19
|
-
- `instantiate_blueprint` → Copies a blueprint into the user's project
|
|
20
|
-
- `save_as_blueprint` → Saves a new high-quality solution as a blueprint
|
|
21
|
-
|
|
22
|
-
## Recommended Folder Structure
|
|
23
|
-
|
|
24
|
-
For a clean and maintainable structure, the following format is recommended:
|
|
25
|
-
|
|
26
|
-
```
|
|
27
|
-
blueprints/
|
|
28
|
-
├── backend/
|
|
29
|
-
│ ├── errors/
|
|
30
|
-
│ │ ├── config/
|
|
31
|
-
│ │ │ └── meta.json # Blueprint metadata
|
|
32
|
-
│ │ └── domain-error.ts # Source code
|
|
33
|
-
│ └── ...
|
|
34
|
-
├── frontend/
|
|
35
|
-
│ └── ...
|
|
36
|
-
├── general/
|
|
37
|
-
│ └── ...
|
|
38
|
-
└── README.md
|
|
39
|
-
```
|
|
40
|
-
|
|
41
|
-
**Mandatory Discipline Rule:**
|
|
42
|
-
Categories without actual content **must not** create folders on disk. Empty folders are only listed as plans in this README. When a new blueprint is added, the relevant folder + `config/meta.json` + source code are added together.
|
|
43
|
-
|
|
44
|
-
Each blueprint folder contains:
|
|
45
|
-
- `config/meta.json` → Blueprint metadata (description, category, version, recommendedPath, etc.)
|
|
46
|
-
- Relevant source code files (at least 1 file)
|
|
47
|
-
|
|
48
|
-
## Maintenance and Discipline Rules (When Content Is Low)
|
|
49
|
-
|
|
50
|
-
This folder must **always** be kept clean and professional. Even with low content, clutter or empty folders are not allowed.
|
|
51
|
-
|
|
52
|
-
- Only blueprints that have actually been added and are working exist as folders on disk.
|
|
53
|
-
- Planned categories (middleware, repositories, frontend/components, etc.) are **only listed as plans in this README**; no folders are created on disk.
|
|
54
|
-
- Every time a new blueprint is added, this README and related knowledge documents are updated.
|
|
55
|
-
- Empty folders are cleaned up or never created (structure governance rule).
|
|
56
|
-
|
|
57
|
-
## Current Blueprints
|
|
58
|
-
|
|
59
|
-
Currently there is only 1 mature example:
|
|
60
|
-
|
|
61
|
-
- `backend/errors/` → DomainError-based error system (Gold Standard)
|
|
62
|
-
- `config/meta.json`
|
|
63
|
-
- `domain-error.ts`
|
|
64
|
-
|
|
65
|
-
Other categories (middleware, repositories, frontend, general) do not yet have content, so no folders exist on disk.
|
|
66
|
-
|
|
67
|
-
## Rules for Adding New Blueprints
|
|
68
|
-
|
|
69
|
-
1. Only truly high-quality and repeatable solutions should be saved as blueprints.
|
|
70
|
-
2. Every blueprint must have a short description inside `config/meta.json`.
|
|
71
|
-
3. Blueprints should be as framework-agnostic as possible (easy to adapt when copied).
|
|
72
|
-
4. Before adding a new blueprint, check with `list_blueprints` whether something similar already exists.
|
|
73
|
-
5. **When adding a new blueprint, the folder + config/meta.json + at least one source code file must be added together.** Empty folders are not created.
|
|
74
|
-
|
|
75
|
-
## Related Documents
|
|
76
|
-
|
|
77
|
-
- `.antigravitycli/knowledge/blueprint_driven_construction.md` (Blueprint usage philosophy)
|
|
78
|
-
- `framework-mcp/src/tools/scaffold.ts` (Technical implementation)
|
|
79
|
-
|
|
80
|
-
---
|
|
81
|
-
|
|
82
|
-
**Note:** This folder must be dynamically grown by the agents. Even with low content, it must be kept **organized, documented, and disciplined** at all times (structure governance rule 2026-05-24 item 2).
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "backend/errors/domain-error",
|
|
3
|
-
"version": "1.0.0",
|
|
4
|
-
"category": "backend",
|
|
5
|
-
"description": "Standardized DomainError hierarchy with 6 core error types. Enforces Zero Mock and Branded Error patterns.",
|
|
6
|
-
"tags": [
|
|
7
|
-
"error-handling",
|
|
8
|
-
"backend",
|
|
9
|
-
"gold-standard",
|
|
10
|
-
"domain-driven"
|
|
11
|
-
],
|
|
12
|
-
"recommendedPath": "apps/backend/src/errors/domain-error.ts",
|
|
13
|
-
"dependencies": [],
|
|
14
|
-
"createdAt": "2026-05-23",
|
|
15
|
-
"author": "@backend"
|
|
16
|
-
}
|
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* GOLD STANDARD BLUEPRINT
|
|
3
|
-
* Category: backend/errors
|
|
4
|
-
* Name: DomainError Hierarchy
|
|
5
|
-
* Version: 1.0.0
|
|
6
|
-
* Description: Standardized, typed error system for all backend services.
|
|
7
|
-
*
|
|
8
|
-
* Usage:
|
|
9
|
-
* 1. Copy this file to apps/backend/src/errors/domain-error.ts
|
|
10
|
-
* 2. Create index.ts to re-export all error classes
|
|
11
|
-
* 3. Import and use in controllers/services (never throw raw Error)
|
|
12
|
-
*/
|
|
13
|
-
|
|
14
|
-
export abstract class DomainError extends Error {
|
|
15
|
-
public readonly statusCode: number;
|
|
16
|
-
public readonly code: string;
|
|
17
|
-
|
|
18
|
-
constructor(message: string, statusCode: number, code: string) {
|
|
19
|
-
super(message);
|
|
20
|
-
this.name = this.constructor.name;
|
|
21
|
-
this.statusCode = statusCode;
|
|
22
|
-
this.code = code;
|
|
23
|
-
Error.captureStackTrace(this, this.constructor);
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
export class NotFoundError extends DomainError {
|
|
28
|
-
constructor(resource: string) {
|
|
29
|
-
super(`${resource} not found`, 404, 'NOT_FOUND');
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
export class ValidationError extends DomainError {
|
|
34
|
-
public readonly details?: Record<string, unknown>;
|
|
35
|
-
|
|
36
|
-
constructor(message: string, details?: Record<string, unknown>) {
|
|
37
|
-
super(message, 400, 'VALIDATION_ERROR');
|
|
38
|
-
this.details = details;
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
export class UnauthorizedError extends DomainError {
|
|
43
|
-
constructor(message = 'Unauthorized') {
|
|
44
|
-
super(message, 401, 'UNAUTHORIZED');
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
export class ForbiddenError extends DomainError {
|
|
49
|
-
constructor(message = 'Forbidden') {
|
|
50
|
-
super(message, 403, 'FORBIDDEN');
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
export class ConflictError extends DomainError {
|
|
55
|
-
constructor(message: string) {
|
|
56
|
-
super(message, 409, 'CONFLICT');
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
export class InternalServerError extends DomainError {
|
|
61
|
-
constructor(message = 'Internal server error') {
|
|
62
|
-
super(message, 500, 'INTERNAL_ERROR');
|
|
63
|
-
}
|
|
64
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
# Knowledge Base
|
|
2
|
-
|
|
3
|
-
This directory is the **permanent enterprise knowledge** repository for Agent Enderun agents.
|
|
4
|
-
|
|
5
|
-
## Content Rules
|
|
6
|
-
- File names **must** be in kebab-case (`hermes-protocol.md`, `enterprise-project-adaptation.md`).
|
|
7
|
-
- Every file must contain a clear title and "Version / Owner / Last Updated" metadata.
|
|
8
|
-
- Knowledge should be as **practical and actionable** as possible (not just theory).
|
|
9
|
-
|
|
10
|
-
## Important Files
|
|
11
|
-
- `enterprise_project_adaptation.md` → Enterprise project entry protocol (EPDP)
|
|
12
|
-
- `enterprise_frontend_adaptation.md` → Enterprise adaptation rules for frontend
|
|
13
|
-
- `hermes_protocol.md` → Inter-agent communication standard
|
|
14
|
-
- `manager_authority_audit_enforcement.md` → @manager authority audit rules
|
|
15
|
-
- `hermes_live_test_guidelines.md` → Hermes test program
|
|
16
|
-
|
|
17
|
-
## Usage
|
|
18
|
-
Agents must search this directory first when conducting research or making decisions (using the `search_knowledge_base` tool).
|
|
19
|
-
|
|
20
|
-
Newly discovered important patterns or rules must be written here.
|
|
21
|
-
|
|
22
|
-
**Last Updated:** 24 May 2026
|
|
@@ -1,118 +0,0 @@
|
|
|
1
|
-
# Enterprise Database Governance and Performance Guidelines (DBA SOP)
|
|
2
|
-
|
|
3
|
-
**Version:** v0.6.5 | **Ownership:** @backend & @dba Security Framework
|
|
4
|
-
|
|
5
|
-
This document is the constitutional database ruleset establishing **Zero-Downtime DDL (schema migrations)**, **maximum query performance (Index Tuning)**, and **deadlock prevention strategies (Lock Management)** in applications running under the PostgreSQL + Kysely architecture. `@backend` executes these rules with 0 error tolerance when writing code, and `@analyst` actively audits them during code review.
|
|
6
|
-
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
## ⚡ 1. INDEX OPTIMIZATION LAWS (INDEX TUNING)
|
|
10
|
-
|
|
11
|
-
To ensure that queries do not exhaust the database and can respond to thousands of requests per second, index design cannot be left to chance.
|
|
12
|
-
|
|
13
|
-
### 1.1 Foreign Key Index Obligation
|
|
14
|
-
* **Rule:** For every Foreign Key (FK) column defined, **it is mandatory to create a corresponding index**.
|
|
15
|
-
* **Rationale:** Prevents sequential scans on the target table during `JOIN` operations and when deleting data from the parent table (`ON DELETE CASCADE`).
|
|
16
|
-
* **Kysely/SQL Pattern:**
|
|
17
|
-
```typescript
|
|
18
|
-
// Inside the migration file
|
|
19
|
-
await db.schema.createIndex('idx_orders_user_id')
|
|
20
|
-
.on('orders')
|
|
21
|
-
.column('user_id')
|
|
22
|
-
.execute();
|
|
23
|
-
```
|
|
24
|
-
|
|
25
|
-
### 1.2 Concurrent Indexing
|
|
26
|
-
* **Rule:** All indexes created on production databases **must be created using the `CONCURRENTLY` keyword**.
|
|
27
|
-
* **Rationale:** Standard index creation locks the target table completely for write operations (`ShareLock`). `CONCURRENTLY` builds the index in the background without locking the table.
|
|
28
|
-
* **Migration Rule:** When creating indexes concurrently, the migration process must run outside of a database transaction. In Kysely, this operation must be run `transaction-free`.
|
|
29
|
-
|
|
30
|
-
### 1.3 Partial & Composite Indexes
|
|
31
|
-
* **Rule:** **Partial Indexes** must be used on tables using soft deletes (`deleted_at IS NOT NULL`) or when queries filter by a specific status.
|
|
32
|
-
* **Kysely Pattern:**
|
|
33
|
-
```typescript
|
|
34
|
-
// An extremely fast and small index that scans only active records
|
|
35
|
-
await db.schema.createIndex('idx_active_users_email')
|
|
36
|
-
.on('users')
|
|
37
|
-
.column('email')
|
|
38
|
-
.where(sql`deleted_at IS NULL`)
|
|
39
|
-
.execute();
|
|
40
|
-
```
|
|
41
|
-
* **Rule 2:** When creating composite indexes for multi-column searches like `WHERE a = x AND b = y`, the **column with the highest selectivity (high cardinality) must be placed on the far left**.
|
|
42
|
-
|
|
43
|
-
---
|
|
44
|
-
|
|
45
|
-
## 🔒 2. DATABASE LOCK MANAGEMENT (LOCK MANAGEMENT)
|
|
46
|
-
|
|
47
|
-
Incorrect lock management leads to connection pool exhaustion within seconds, causing a complete system crash (cascading failure).
|
|
48
|
-
|
|
49
|
-
### 2.1 Transaction Boundaries and Golden Rules
|
|
50
|
-
1. **Zero Network Inside TX:** While a database transaction (`db.transaction()`) is active, **external API calls, sending emails, or file read/write operations are strictly forbidden**. A 1-second network latency causes locks in the database to be held for that second, clogging the entire system.
|
|
51
|
-
2. **Keep it Short Principle:** Transactions must only contain database write operations and must be `committed` as quickly as possible.
|
|
52
|
-
|
|
53
|
-
### 2.2 Deadlock Prevention and Smart Query Design
|
|
54
|
-
* **Rule:** The use of `SELECT ... FOR UPDATE` (Row Lock) is forbidden except in high-urgency scenarios. When its use is mandatory, the query must be restricted with **`NOWAIT`** or **`SKIP LOCKED`** parameters to avoid entering the queue and causing deadlocks.
|
|
55
|
-
* **Kysely Pattern:**
|
|
56
|
-
```typescript
|
|
57
|
-
// Instead of waiting in a queue and locking the system, throw an error or skip if locked
|
|
58
|
-
const job = await db.selectFrom('jobs')
|
|
59
|
-
.selectAll()
|
|
60
|
-
.where('status', '=', 'PENDING')
|
|
61
|
-
.limit(1)
|
|
62
|
-
.forUpdate()
|
|
63
|
-
.skipLocked() // OR .noWait()
|
|
64
|
-
.executeTakeFirst();
|
|
65
|
-
```
|
|
66
|
-
|
|
67
|
-
### 2.3 Timeout Safety
|
|
68
|
-
Lock timeout parameters must be set before every session or heavy migration. This ensures that if a lock accumulation occurs in the background, the transaction cancels itself instead of locking up the system.
|
|
69
|
-
```sql
|
|
70
|
-
SET statement_timeout = '15s';
|
|
71
|
-
SET lock_timeout = '5s';
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
---
|
|
75
|
-
|
|
76
|
-
## 🛡️ 3. SAFE SCHEMA TRANSITION LAWS (SAFE MIGRATIONS - DDL)
|
|
77
|
-
|
|
78
|
-
To ensure zero-downtime during schema migrations on production environments, the following templates must be applied:
|
|
79
|
-
|
|
80
|
-
### 3.1 NOT NULL Column Addition Procedure
|
|
81
|
-
Adding a column containing a `NOT NULL` constraint directly to a production table causes PostgreSQL to lock the entire table. The safe procedure is:
|
|
82
|
-
1. Add the column as **nullable**.
|
|
83
|
-
2. Update the data in the background with default values (in batches).
|
|
84
|
-
3. Add the `NOT NULL` constraint to the column (this operation no longer creates a lock).
|
|
85
|
-
|
|
86
|
-
### 3.2 Breaking Column/Table Changes - "Expand & Contract"
|
|
87
|
-
Renaming a column or changing its data type directly on a live system is strictly forbidden. Instead, follow these 5 steps:
|
|
88
|
-
```
|
|
89
|
-
[Deployment 1 - EXPAND]
|
|
90
|
-
Add the new column. Start dual-writing in the codebase (write to both old and new columns).
|
|
91
|
-
|
|
92
|
-
[Deployment 2 - BACKFILL]
|
|
93
|
-
Migrate legacy data from the old column to the new column in the background (Batch Update).
|
|
94
|
-
|
|
95
|
-
[Deployment 3 - READ SWITCH]
|
|
96
|
-
Redirect all read requests in the codebase to the new column.
|
|
97
|
-
|
|
98
|
-
[Deployment 4 - STOP DUAL-WRITE]
|
|
99
|
-
Completely stop writing to the old column.
|
|
100
|
-
|
|
101
|
-
[Deployment 5 - CONTRACT]
|
|
102
|
-
Delete the old column from the database (Drop Column).
|
|
103
|
-
```
|
|
104
|
-
|
|
105
|
-
### 3.3 Adding Constraints Safely
|
|
106
|
-
To prevent table locks when adding `CHECK` or `FOREIGN KEY` constraints to large tables:
|
|
107
|
-
1. Add the constraint as `NOT VALID` (bypasses scanning legacy data, returns immediately).
|
|
108
|
-
2. Then, validate the constraint in the background by running the `VALIDATE CONSTRAINT` command concurrently.
|
|
109
|
-
|
|
110
|
-
---
|
|
111
|
-
|
|
112
|
-
## 🕵️ 4. AUTOMATED QA GATE CHECKLIST
|
|
113
|
-
|
|
114
|
-
`@analyst` scans the database schema and queries automatically during code review against these rules:
|
|
115
|
-
* [ ] For every new `table.foreign()` definition, is a corresponding `createIndex()` defined?
|
|
116
|
-
* [ ] Is `.forUpdate()` used in any `selectFrom` query without `.skipLocked()` or `.noWait()` written next to it?
|
|
117
|
-
* [ ] Is there any `alterTable().renameColumn()` or direct destructive `dropColumn()` in migration files? (Expand/Contract audit).
|
|
118
|
-
* [ ] Is `CONCURRENTLY` used in index additions on large tables?
|