avorelo 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +56 -0
- package/bin/avorelo +9 -0
- package/package.json +135 -0
- package/scripts/README.md +40 -0
- package/scripts/cco-dashboard.js +252 -0
- package/scripts/cco-status.js +430 -0
- package/scripts/lib/activation/account-state.js +37 -0
- package/scripts/lib/activation/activation-runner.js +546 -0
- package/scripts/lib/activation/activation-self-healing.js +480 -0
- package/scripts/lib/activation/activation-state.js +83 -0
- package/scripts/lib/activation/activation-summary.js +191 -0
- package/scripts/lib/activation/adapters/claude-code.js +77 -0
- package/scripts/lib/activation/adapters/codex-cli.js +52 -0
- package/scripts/lib/activation/adapters/cursor.js +37 -0
- package/scripts/lib/activation/adapters/github-agent.js +39 -0
- package/scripts/lib/activation/adapters/terminal.js +42 -0
- package/scripts/lib/activation/adapters/vscode.js +39 -0
- package/scripts/lib/activation/adapters/windsurf.js +37 -0
- package/scripts/lib/activation/ai-surface-detector.js +151 -0
- package/scripts/lib/activation/connect-account.js +145 -0
- package/scripts/lib/activation/detect-environment.js +75 -0
- package/scripts/lib/activation/detect-hosts.js +62 -0
- package/scripts/lib/activation/format-activation-output.js +109 -0
- package/scripts/lib/activation/next-action.js +43 -0
- package/scripts/lib/activation/repair-engine.js +219 -0
- package/scripts/lib/activation-distribution-readiness.js +507 -0
- package/scripts/lib/adapter-conformance.js +176 -0
- package/scripts/lib/adapter-readiness.js +417 -0
- package/scripts/lib/adapter-safety-boundaries.js +335 -0
- package/scripts/lib/adapter-technical-readiness-gate.js +205 -0
- package/scripts/lib/agent-access-governance.js +455 -0
- package/scripts/lib/agent-enforcement.js +765 -0
- package/scripts/lib/agent-policy-profile.js +210 -0
- package/scripts/lib/agent-security/action-evaluator.js +507 -0
- package/scripts/lib/agent-security/adapter-registry.js +98 -0
- package/scripts/lib/agent-security/auto-policy.js +139 -0
- package/scripts/lib/agent-security/bounded-scan.js +93 -0
- package/scripts/lib/agent-security/enforcement-adapter.js +174 -0
- package/scripts/lib/agent-security/enforcement-engine.js +1129 -0
- package/scripts/lib/agent-security/file-write-adapter.js +183 -0
- package/scripts/lib/agent-security/file-write-rules.js +178 -0
- package/scripts/lib/agent-security/index.js +3342 -0
- package/scripts/lib/agent-security/instruction-risk.js +181 -0
- package/scripts/lib/agent-security/mcp-action-adapter.js +185 -0
- package/scripts/lib/agent-security/mcp-action-rules.js +184 -0
- package/scripts/lib/agent-security/package-action-adapter.js +175 -0
- package/scripts/lib/agent-security/package-action-rules.js +233 -0
- package/scripts/lib/agent-security/performance.js +148 -0
- package/scripts/lib/agent-security/permission-minimizer.js +403 -0
- package/scripts/lib/agent-security/scan-cache.js +74 -0
- package/scripts/lib/agent-security/source-trust.js +146 -0
- package/scripts/lib/ai-install-prompt.js +288 -0
- package/scripts/lib/ai-workspace-hygiene.js +1499 -0
- package/scripts/lib/alpha-activation.js +520 -0
- package/scripts/lib/alpha-feedback.js +263 -0
- package/scripts/lib/alpha-readiness-gate.js +332 -0
- package/scripts/lib/anti-gaming.js +169 -0
- package/scripts/lib/artifact-health.js +431 -0
- package/scripts/lib/attribution.js +180 -0
- package/scripts/lib/audit.js +289 -0
- package/scripts/lib/avorelo-skill-registry.js +810 -0
- package/scripts/lib/batch-jobs.js +71 -0
- package/scripts/lib/brain-pack.js +578 -0
- package/scripts/lib/brand-boundary.js +424 -0
- package/scripts/lib/brand.js +74 -0
- package/scripts/lib/browser-capability.js +1048 -0
- package/scripts/lib/browser-proof-preflight.js +321 -0
- package/scripts/lib/cache-readiness.js +187 -0
- package/scripts/lib/canonical-reentry.js +162 -0
- package/scripts/lib/capability-packs.js +314 -0
- package/scripts/lib/capability-recommender.js +512 -0
- package/scripts/lib/capability-registry.js +1059 -0
- package/scripts/lib/carry-forward-surfacing.js +194 -0
- package/scripts/lib/ccusage-adapter.js +188 -0
- package/scripts/lib/company-loop.js +1149 -0
- package/scripts/lib/config.js +637 -0
- package/scripts/lib/context-acquisition-plan.js +287 -0
- package/scripts/lib/context-budget-guard.js +170 -0
- package/scripts/lib/context-budget-scanner.js +257 -0
- package/scripts/lib/context-optimizer.js +715 -0
- package/scripts/lib/context-reduction-plan.js +178 -0
- package/scripts/lib/context-safety.js +88 -0
- package/scripts/lib/context-savings-engine.js +158 -0
- package/scripts/lib/cost-evidence.js +254 -0
- package/scripts/lib/cross-host-install-plan.js +308 -0
- package/scripts/lib/cross-host-install-readiness.js +237 -0
- package/scripts/lib/cross-host-value-flow.js +268 -0
- package/scripts/lib/dashboard.js +900 -0
- package/scripts/lib/design-partner-feedback.js +346 -0
- package/scripts/lib/entitlements.js +100 -0
- package/scripts/lib/execution-packet.js +559 -0
- package/scripts/lib/experimentation-events.js +547 -0
- package/scripts/lib/external-capability-compliance.js +107 -0
- package/scripts/lib/external-user-simulation.js +166 -0
- package/scripts/lib/failure-recovery-readiness.js +81 -0
- package/scripts/lib/failure-recovery.js +419 -0
- package/scripts/lib/feedback-intelligence.js +537 -0
- package/scripts/lib/feedback-signals.js +205 -0
- package/scripts/lib/file-integrity.js +68 -0
- package/scripts/lib/fsx.js +127 -0
- package/scripts/lib/full-readiness-gate.js +451 -0
- package/scripts/lib/guidance-builder.js +174 -0
- package/scripts/lib/hook-apply.js +1019 -0
- package/scripts/lib/hook-baseline.js +310 -0
- package/scripts/lib/hook-config-preview.js +275 -0
- package/scripts/lib/hook-contracts.js +290 -0
- package/scripts/lib/hook-safety-boundary-readiness.js +80 -0
- package/scripts/lib/host-capability-matrix.js +351 -0
- package/scripts/lib/host-support-context.js +254 -0
- package/scripts/lib/http-hook-action.js +538 -0
- package/scripts/lib/install-ai-readiness.js +84 -0
- package/scripts/lib/install-intake-risk.js +1037 -0
- package/scripts/lib/install-journey-intelligence.js +329 -0
- package/scripts/lib/intervention-guidance.js +57 -0
- package/scripts/lib/known-limitations.js +115 -0
- package/scripts/lib/l8-path-truth.js +146 -0
- package/scripts/lib/launch-hardening-gate.js +436 -0
- package/scripts/lib/launch-readiness.js +628 -0
- package/scripts/lib/learning-memory.js +686 -0
- package/scripts/lib/lifecycle-hooks.js +802 -0
- package/scripts/lib/local-package-smoke.js +423 -0
- package/scripts/lib/local-pricing.js +299 -0
- package/scripts/lib/mcp-enforcement.js +311 -0
- package/scripts/lib/mcp-least-privilege-policy.js +303 -0
- package/scripts/lib/mcp-tool-inventory.js +388 -0
- package/scripts/lib/mcp-tool-risk.js +0 -0
- package/scripts/lib/memory.js +335 -0
- package/scripts/lib/metrics.js +699 -0
- package/scripts/lib/micro-proof.js +133 -0
- package/scripts/lib/next-run-context.js +436 -0
- package/scripts/lib/operating-value.js +1648 -0
- package/scripts/lib/optimization-v3.js +122 -0
- package/scripts/lib/orchestration/adapters/_shared.js +49 -0
- package/scripts/lib/orchestration/adapters/aider.js +18 -0
- package/scripts/lib/orchestration/adapters/claude-code.js +35 -0
- package/scripts/lib/orchestration/adapters/codex.js +35 -0
- package/scripts/lib/orchestration/adapters/gemini-cli.js +18 -0
- package/scripts/lib/orchestration/adapters/git.js +25 -0
- package/scripts/lib/orchestration/adapters/index.js +31 -0
- package/scripts/lib/orchestration/adapters/lm-studio.js +18 -0
- package/scripts/lib/orchestration/adapters/ollama.js +18 -0
- package/scripts/lib/orchestration/adapters/opencode.js +18 -0
- package/scripts/lib/orchestration/adapters/openrouter.js +18 -0
- package/scripts/lib/orchestration/adapters/test-runner.js +25 -0
- package/scripts/lib/orchestration/cli.js +438 -0
- package/scripts/lib/orchestration/execution-manager.js +279 -0
- package/scripts/lib/orchestration/handoff.js +314 -0
- package/scripts/lib/orchestration/index.js +456 -0
- package/scripts/lib/orchestration/inventory.js +47 -0
- package/scripts/lib/orchestration/model-discovery.js +498 -0
- package/scripts/lib/orchestration/model-profiler.js +170 -0
- package/scripts/lib/orchestration/model-profiles.js +252 -0
- package/scripts/lib/orchestration/model-refresh-policy.js +72 -0
- package/scripts/lib/orchestration/proof-writer.js +349 -0
- package/scripts/lib/orchestration/provider-discovery/aider.js +49 -0
- package/scripts/lib/orchestration/provider-discovery/claude-code.js +56 -0
- package/scripts/lib/orchestration/provider-discovery/codex.js +49 -0
- package/scripts/lib/orchestration/provider-discovery/common.js +186 -0
- package/scripts/lib/orchestration/provider-discovery/gemini.js +106 -0
- package/scripts/lib/orchestration/provider-discovery/lm-studio.js +118 -0
- package/scripts/lib/orchestration/provider-discovery/models-dev.js +12 -0
- package/scripts/lib/orchestration/provider-discovery/ollama.js +100 -0
- package/scripts/lib/orchestration/provider-discovery/opencode.js +47 -0
- package/scripts/lib/orchestration/provider-discovery/openrouter.js +44 -0
- package/scripts/lib/orchestration/risk-classifier.js +130 -0
- package/scripts/lib/orchestration/routing-policy.js +486 -0
- package/scripts/lib/orchestration/settings.js +112 -0
- package/scripts/lib/orchestration/state.js +165 -0
- package/scripts/lib/orchestration/verification-manager.js +138 -0
- package/scripts/lib/output-profiles.js +146 -0
- package/scripts/lib/package-content-audit.js +368 -0
- package/scripts/lib/package-runtime.js +278 -0
- package/scripts/lib/plan-surface.js +53 -0
- package/scripts/lib/plans.js +2318 -0
- package/scripts/lib/policy-provider.js +27 -0
- package/scripts/lib/prelaunch-activation-readiness.js +409 -0
- package/scripts/lib/prelaunch-evidence-store.js +816 -0
- package/scripts/lib/prelaunch-intelligence.js +869 -0
- package/scripts/lib/pricing-experiment.js +118 -0
- package/scripts/lib/pro-moment-events.js +77 -0
- package/scripts/lib/pro-moment-state.js +227 -0
- package/scripts/lib/pro-moments.js +1216 -0
- package/scripts/lib/product-learning-events.js +629 -0
- package/scripts/lib/project-profile.js +555 -0
- package/scripts/lib/prompt-compiler.js +280 -0
- package/scripts/lib/prompt-lint.js +32 -0
- package/scripts/lib/prompt-suggestions.js +52 -0
- package/scripts/lib/proof-canonical.js +398 -0
- package/scripts/lib/proof-drilldown.js +383 -0
- package/scripts/lib/proof-events.js +342 -0
- package/scripts/lib/proof-history.js +243 -0
- package/scripts/lib/proof-metrics.js +296 -0
- package/scripts/lib/proof-outcome-evidence.js +134 -0
- package/scripts/lib/proof-receipt.js +335 -0
- package/scripts/lib/proof-record.js +461 -0
- package/scripts/lib/public-activation-distribution-gate.js +258 -0
- package/scripts/lib/public-cli.js +3891 -0
- package/scripts/lib/public-distribution-truth.js +211 -0
- package/scripts/lib/public-install-claim-checker.js +294 -0
- package/scripts/lib/publish-provenance-readiness.js +283 -0
- package/scripts/lib/readiness-delta.js +218 -0
- package/scripts/lib/readiness-evidence-closure.js +196 -0
- package/scripts/lib/reentry-memory-capture.js +241 -0
- package/scripts/lib/reentry-memory-retrieval.js +302 -0
- package/scripts/lib/reentry-memory-status.js +146 -0
- package/scripts/lib/reentry-memory-store.js +178 -0
- package/scripts/lib/reentry-state.js +66 -0
- package/scripts/lib/release-candidate-bundle.js +166 -0
- package/scripts/lib/remediation.js +81 -0
- package/scripts/lib/repo-map.js +391 -0
- package/scripts/lib/run-improvements-lifecycle.js +330 -0
- package/scripts/lib/run-improvements.js +789 -0
- package/scripts/lib/runtime-decision-policy.js +387 -0
- package/scripts/lib/safe-path-engine.js +705 -0
- package/scripts/lib/safe-run-controller.js +887 -0
- package/scripts/lib/score.js +262 -0
- package/scripts/lib/seamless-enforcement.js +329 -0
- package/scripts/lib/seamless-outcome.js +689 -0
- package/scripts/lib/seamless-reality-gate.js +5043 -0
- package/scripts/lib/security-risk-classifier.js +511 -0
- package/scripts/lib/security-scan.js +384 -0
- package/scripts/lib/session-context-optimizer.js +1211 -0
- package/scripts/lib/session-timing.js +315 -0
- package/scripts/lib/skill-hygiene.js +805 -0
- package/scripts/lib/skill-packs.js +161 -0
- package/scripts/lib/skills-operating-layer.js +580 -0
- package/scripts/lib/smart-work-routing.js +768 -0
- package/scripts/lib/source-catalog.js +700 -0
- package/scripts/lib/status-value-summary.js +32 -0
- package/scripts/lib/support-bundle.js +578 -0
- package/scripts/lib/task-continuation.js +440 -0
- package/scripts/lib/test-helpers.js +15 -0
- package/scripts/lib/tier.js +38 -0
- package/scripts/lib/token-context-quality-gate.js +370 -0
- package/scripts/lib/token-cost-capture.js +187 -0
- package/scripts/lib/token-cost-intelligence.js +358 -0
- package/scripts/lib/token-efficiency-evidence.js +213 -0
- package/scripts/lib/token-evidence.js +699 -0
- package/scripts/lib/tokenish.js +17 -0
- package/scripts/lib/tool-output-sandbox.js +304 -0
- package/scripts/lib/trust-audit.js +136 -0
- package/scripts/lib/unified-events.js +396 -0
- package/scripts/lib/upgrade-interruption-recovery.js +407 -0
- package/scripts/lib/usage-ledger.js +201 -0
- package/scripts/lib/value-ledger.js +130 -0
- package/scripts/lib/value-proof-calibration.js +531 -0
- package/scripts/lib/visual-qa.js +231 -0
- package/scripts/lib/voice-alpha.js +29 -0
- package/scripts/lib/work-aware-orchestration.js +976 -0
- package/scripts/lib/work-control-receipts.js +577 -0
- package/scripts/lib/work-ledger.js +1123 -0
- package/scripts/lib/work-panel-preview.js +352 -0
- package/scripts/lib/workflow-discipline.js +280 -0
- package/scripts/lib/workflow-signals.js +419 -0
- package/scripts/lib/workspace-map.js +281 -0
- package/scripts/lib/workspace-registry.js +1367 -0
- package/scripts/lib/workspace-resolver.js +480 -0
|
@@ -0,0 +1,314 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
const { getCapability: getPlanCapability, CAPABILITIES } = require("./plans");
|
|
4
|
+
|
|
5
|
+
const CAPABILITY_PACKS = Object.freeze([
|
|
6
|
+
{
|
|
7
|
+
id: "install_intake_risk",
|
|
8
|
+
name: "Install / Intake Risk",
|
|
9
|
+
description: "See what tools, packages, MCP servers, extensions, guidance, and skill sources are entering the workspace before they become trusted runtime surfaces.",
|
|
10
|
+
outcomes: [
|
|
11
|
+
"Local intake items are classified as reviewed, known, unknown, deferred, or blocked.",
|
|
12
|
+
"Risky install/runtime characteristics are surfaced for packages, MCP, extensions, connectors, skills, and guidance.",
|
|
13
|
+
"Governance and Safe Path receive bounded intake reason codes and safe next actions.",
|
|
14
|
+
"Compact local receipts keep intake evidence without registry lookups or cloud scanning.",
|
|
15
|
+
],
|
|
16
|
+
capabilityIds: [
|
|
17
|
+
"install_intake_risk_basic",
|
|
18
|
+
"mcp_intake_visibility_basic",
|
|
19
|
+
"package_intake_visibility_basic",
|
|
20
|
+
"extension_intake_visibility_basic",
|
|
21
|
+
"connector_intake_visibility_basic",
|
|
22
|
+
"skill_source_intake_risk_basic",
|
|
23
|
+
"intake_safe_next_action_basic",
|
|
24
|
+
"intake_receipt_basic",
|
|
25
|
+
],
|
|
26
|
+
defaultEntitlement: "free",
|
|
27
|
+
recommendationSignals: ["package_manifest_present", "source_catalog_present", "skills_present", "security_signals", "safe_path_receipt_present"],
|
|
28
|
+
statusCopy: "Install / Intake Risk: local intake visibility, classification, and compact receipts are available.",
|
|
29
|
+
dashboardCopy: "Avorelo can classify local intake items, surface risky install/runtime characteristics, and feed governance and Safe Path without registry lookups or malware claims.",
|
|
30
|
+
userFacingCopy: "Know what is entering the workspace before it becomes trusted runtime access. Avorelo scans local intake surfaces, classifies reviewed versus unknown sources, explains risky characteristics, and suggests the next safe step.",
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
id: "source_backed_skills",
|
|
34
|
+
name: "Source-Backed Skills",
|
|
35
|
+
description: "Review, parse, bind, and route local or reviewed external skills without turning Avorelo into a marketplace.",
|
|
36
|
+
outcomes: [
|
|
37
|
+
"Reviewed and deferred sources are visible locally.",
|
|
38
|
+
"SKILL.md files are parsed into deterministic routing metadata.",
|
|
39
|
+
"Tasks route to relevant skills with compact summaries and evidence expectations.",
|
|
40
|
+
"Thin adapter guidance is generated from local source truth instead of duplicated prompt bodies.",
|
|
41
|
+
],
|
|
42
|
+
capabilityIds: [
|
|
43
|
+
"reference_source_intake_basic",
|
|
44
|
+
"skill_md_parser_basic",
|
|
45
|
+
"skill_pattern_extraction_basic",
|
|
46
|
+
"skill_trust_scan_basic",
|
|
47
|
+
"capability_binding_basic",
|
|
48
|
+
"source_backed_skill_router_basic",
|
|
49
|
+
"thin_adapter_guidance_sync_basic",
|
|
50
|
+
],
|
|
51
|
+
defaultEntitlement: "free",
|
|
52
|
+
recommendationSignals: ["source_catalog_present", "skills_present", "reference_backed_task"],
|
|
53
|
+
statusCopy: "Source-Backed Skills: reviewed sources, parsed skills, and deterministic routing are available.",
|
|
54
|
+
dashboardCopy: "Avorelo can review sources, parse skills, route tasks to selected skill paths, and generate thin adapter guidance without broad prompt dumps.",
|
|
55
|
+
userFacingCopy: "Use strong skill systems safely. Avorelo reviews source metadata, parses relevant skills, binds them to capabilities, routes only the needed guidance, and keeps adapters thin.",
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
id: "agent_readiness",
|
|
59
|
+
name: "Agent Readiness",
|
|
60
|
+
description: "Start safely and effectively in a repo with the right context, checks, and next actions.",
|
|
61
|
+
outcomes: [
|
|
62
|
+
"Avorelo is activated and ready in the current repo.",
|
|
63
|
+
"Readiness gaps are surfaced before AI work begins.",
|
|
64
|
+
"Agent has the right context to start effectively.",
|
|
65
|
+
"Next best action is clear.",
|
|
66
|
+
],
|
|
67
|
+
capabilityIds: ["local_activation", "ai_coding_readiness", "session_handoff_basic"],
|
|
68
|
+
defaultEntitlement: "free",
|
|
69
|
+
recommendationSignals: ["no_activation_state", "first_run", "doctor_not_run"],
|
|
70
|
+
statusCopy: "Agent Readiness: activation, readiness, and carry-forward checks are available.",
|
|
71
|
+
dashboardCopy: "Avorelo checks activation state, readiness gaps, and session carry-forward before broad work begins.",
|
|
72
|
+
userFacingCopy: "Give your agent the right starting context. Avorelo checks that your repo is ready for AI work, surfaces gaps, and carries forward useful recent state.",
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
id: "agent_security",
|
|
76
|
+
name: "Agent Security",
|
|
77
|
+
description: "Keep agents useful without giving them unlimited power. Detect risk, apply guardrails, and produce evidence.",
|
|
78
|
+
outcomes: [
|
|
79
|
+
"Risky instructions and prompts are flagged before harm.",
|
|
80
|
+
"Untrusted sources and risky tools are classified.",
|
|
81
|
+
"Sensitive actions require approval or are blocked.",
|
|
82
|
+
"Local evidence is kept for evaluated actions.",
|
|
83
|
+
],
|
|
84
|
+
capabilityIds: [
|
|
85
|
+
"skills_security_basic",
|
|
86
|
+
"instruction_risk_basic",
|
|
87
|
+
"prompt_injection_basic",
|
|
88
|
+
"source_trust_basic",
|
|
89
|
+
"tool_risk_basic",
|
|
90
|
+
"mcp_tool_risk_basic",
|
|
91
|
+
"sensitive_file_guard",
|
|
92
|
+
"secret_exposure_guard",
|
|
93
|
+
"destructive_command_guard",
|
|
94
|
+
"scoped_action_guard_basic",
|
|
95
|
+
"enforcement_evidence",
|
|
96
|
+
],
|
|
97
|
+
defaultEntitlement: "free",
|
|
98
|
+
recommendationSignals: ["risky_intercepts_detected", "high_risk_level", "trust_alerts_detected", "security_signals"],
|
|
99
|
+
statusCopy: "Agent Security: risky instructions, tools, source trust, and action guardrails are active.",
|
|
100
|
+
dashboardCopy: "Avorelo guards against risky agent behavior by flagging unsafe instructions, risky tools, and sensitive actions before they cause harm.",
|
|
101
|
+
userFacingCopy: "Keep your agent useful without giving it unlimited power. Avorelo detects risky instructions, untrusted sources, and sensitive actions, then keeps local evidence of what was allowed, warned, or blocked.",
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
id: "safe_path_engine",
|
|
105
|
+
name: "Safe Path Engine",
|
|
106
|
+
description: "Turn risky requests into bounded safer alternatives with reduced scope, approval boundaries, and local evidence.",
|
|
107
|
+
outcomes: [
|
|
108
|
+
"Risky actions get a deterministic Safe Path recommendation instead of only risky or blocked.",
|
|
109
|
+
"Least-privilege scope reductions are suggested for paths, domains, tools, and access mode.",
|
|
110
|
+
"Approval boundaries and JIT-style temporary scope fields are visible where supported.",
|
|
111
|
+
"Skill evidence requirements and context-safety warnings can flow into the final recommendation.",
|
|
112
|
+
],
|
|
113
|
+
capabilityIds: [
|
|
114
|
+
"safe_path_recommendation_basic",
|
|
115
|
+
"least_privilege_scope_reduction_basic",
|
|
116
|
+
"jit_temporary_scope_fields_basic",
|
|
117
|
+
"approval_boundary_safe_path_basic",
|
|
118
|
+
"safe_path_receipt_basic",
|
|
119
|
+
"skills_security_dogfood_basic",
|
|
120
|
+
"skill_route_context_safety_basic",
|
|
121
|
+
],
|
|
122
|
+
defaultEntitlement: "free",
|
|
123
|
+
recommendationSignals: ["approval_boundary_present", "guard_receipt_present", "safe_path_receipt_present", "security_signals"],
|
|
124
|
+
statusCopy: "Safe Path Engine: reduced-scope recommendations, approval boundaries, and local receipts are available.",
|
|
125
|
+
dashboardCopy: "Avorelo can preserve blocks, recommend smaller safer scope, and keep evidence-backed approval boundaries without claiming universal enforcement.",
|
|
126
|
+
userFacingCopy: "Do the smallest safe thing that still works. Avorelo turns risky requests into bounded safer alternatives, reduced-scope recommendations, and local evidence-backed approval paths.",
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
id: "workflow_efficiency",
|
|
130
|
+
name: "Workflow Efficiency",
|
|
131
|
+
description: "Reduce wasted AI work, context pressure, retries, and unclear tasks.",
|
|
132
|
+
outcomes: [
|
|
133
|
+
"Context pressure is visible before it causes wasted work.",
|
|
134
|
+
"Sessions resume with carry-forward state rather than starting cold.",
|
|
135
|
+
"Rough instructions are compiled into structured tasks.",
|
|
136
|
+
"Next action is clear and bounded.",
|
|
137
|
+
],
|
|
138
|
+
capabilityIds: ["prompt_compiler_basic", "context_cost_basic", "session_handoff_basic"],
|
|
139
|
+
defaultEntitlement: "free",
|
|
140
|
+
recommendationSignals: ["context_pressure_critical", "context_pressure_warn", "reentry_state_available", "workflow_signals"],
|
|
141
|
+
statusCopy: "Workflow Efficiency: context budget, carry-forward, and prompt compiler are available.",
|
|
142
|
+
dashboardCopy: "Avorelo reduces wasted AI work by keeping context pressure visible, carrying forward useful state, and helping you write clearer tasks.",
|
|
143
|
+
userFacingCopy: "Stop wasting AI work on context pressure, cold restarts, and unclear instructions. Avorelo keeps your agent focused, carries forward useful state, and compiles rough instructions into structured tasks.",
|
|
144
|
+
},
|
|
145
|
+
{
|
|
146
|
+
id: "frontend_readiness",
|
|
147
|
+
name: "Frontend Readiness",
|
|
148
|
+
description: "Prepare AI-generated UI and pages for release with local checks and evidence.",
|
|
149
|
+
outcomes: [
|
|
150
|
+
"AI-generated UI changes are verified with local screenshots when configured.",
|
|
151
|
+
"Browser scope is classified before agent uses browser tooling.",
|
|
152
|
+
"Frontend readiness gaps are surfaced with next actions.",
|
|
153
|
+
],
|
|
154
|
+
capabilityIds: ["visual_qa_weekly", "browser_capability_basic"],
|
|
155
|
+
defaultEntitlement: "free",
|
|
156
|
+
recommendationSignals: ["frontend_detected", "playwright_config_exists", "browser_work_detected"],
|
|
157
|
+
statusCopy: "Frontend Readiness: Visual QA and browser capability checks are available.",
|
|
158
|
+
dashboardCopy: "Avorelo prepares AI-generated UI for release with screenshot-backed Visual QA, browser scope classification, and local evidence.",
|
|
159
|
+
userFacingCopy: "Prepare AI-generated pages and features for release. Avorelo can run local screenshot-backed Visual QA when configured, classify browser scope, and keep evidence of what was checked.",
|
|
160
|
+
productNotes: "Visual QA is one capability in this pack, not the product identity.",
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
id: "workspace_navigation",
|
|
164
|
+
name: "Workspace Navigation",
|
|
165
|
+
description: "Create compact repo navigation context so agents stop rediscovering the same surfaces.",
|
|
166
|
+
outcomes: [
|
|
167
|
+
"Workspace surfaces are mapped into one local artifact.",
|
|
168
|
+
"Agents get likely files, tests, docs, and safety boundaries without broad scans.",
|
|
169
|
+
"Top gaps and next actions are clear.",
|
|
170
|
+
],
|
|
171
|
+
capabilityIds: ["workspace_map_basic", "context_cost_basic"],
|
|
172
|
+
defaultEntitlement: "free",
|
|
173
|
+
recommendationSignals: ["large_repo", "reentry_state_available", "context_pressure_warn"],
|
|
174
|
+
statusCopy: "Workspace Navigation: a compact Workspace Map can be generated for repo-aware work.",
|
|
175
|
+
dashboardCopy: "Avorelo can generate a compact Workspace Map so agents navigate with less rediscovery and less context waste.",
|
|
176
|
+
userFacingCopy: "Stop making agents rediscover the repo. Avorelo can generate a compact Workspace Map with the files, tests, docs, safety boundaries, and next actions that matter.",
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
id: "release_readiness",
|
|
180
|
+
name: "Release Readiness",
|
|
181
|
+
description: "Verify that a change is ready to ship with proof and next actions.",
|
|
182
|
+
outcomes: [
|
|
183
|
+
"Release decisions are backed by local proof of what changed.",
|
|
184
|
+
"Remaining risks and gaps are surfaced before shipping.",
|
|
185
|
+
"Evidence is available for review.",
|
|
186
|
+
],
|
|
187
|
+
capabilityIds: ["evidence_latest", "enforcement_evidence"],
|
|
188
|
+
defaultEntitlement: "free",
|
|
189
|
+
recommendationSignals: ["staged_changes", "validation_passed", "has_staged_changes", "validation_state_partial"],
|
|
190
|
+
statusCopy: "Release Readiness: local evidence and proof summary are available for review.",
|
|
191
|
+
dashboardCopy: "Avorelo verifies release readiness with local proof of what changed, what was checked, and what remains.",
|
|
192
|
+
userFacingCopy: "Know whether it is ready to ship. Avorelo surfaces your local proof, what changed, what was checked, what remains, and a clear next action.",
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
id: "context_intelligence",
|
|
196
|
+
name: "Context Intelligence",
|
|
197
|
+
description: "Give every AI session exactly what matters: current state, relevant project brain, recommended capability, exact commands, what not to repeat, and the safest next action.",
|
|
198
|
+
outcomes: [
|
|
199
|
+
"Session context includes a compact Brain Pack with stable project/repo/user context.",
|
|
200
|
+
"Relevant commands vary by task and target instead of being a static list.",
|
|
201
|
+
"Session context is tailored for Claude, Codex, local model, or generic targets.",
|
|
202
|
+
"Skills route fallback appears when no receipt exists and the task is suitable.",
|
|
203
|
+
"Capability recommender output is embedded — no duplicate routing table.",
|
|
204
|
+
"Dogfood feedback is captured as structured product-learning events.",
|
|
205
|
+
],
|
|
206
|
+
capabilityIds: [
|
|
207
|
+
"brain_pack_basic",
|
|
208
|
+
"recipe_detection_basic",
|
|
209
|
+
"target_specific_handoff_basic",
|
|
210
|
+
"dynamic_session_commands_basic",
|
|
211
|
+
"capability_recommender_context_bridge_basic",
|
|
212
|
+
"skills_route_fallback_basic",
|
|
213
|
+
"dogfood_feedback_loop_basic",
|
|
214
|
+
"task_context_pack_basic",
|
|
215
|
+
"compact_session_context_basic",
|
|
216
|
+
"continuation_packet_basic",
|
|
217
|
+
"context_budget_guard_basic",
|
|
218
|
+
],
|
|
219
|
+
defaultEntitlement: "free",
|
|
220
|
+
recommendationSignals: ["session_context_missing", "brain_pack_missing", "context_pressure_warn", "reentry_state_available"],
|
|
221
|
+
statusCopy: "Context Intelligence: Brain Pack, dynamic commands, target-specific handoff, and capability bridge are available.",
|
|
222
|
+
dashboardCopy: "Avorelo starts every session with exactly what matters: current state, project brain, recommended capability, and exact commands — no broad rediscovery.",
|
|
223
|
+
userFacingCopy: "Start every AI session with the right context. Avorelo generates a compact brain pack, recommends the right capability, adapts commands to the task and target, and keeps agents from rediscovering the repo.",
|
|
224
|
+
},
|
|
225
|
+
]);
|
|
226
|
+
|
|
227
|
+
const PACK_MAP = new Map(CAPABILITY_PACKS.map((pack) => [pack.id, pack]));
|
|
228
|
+
const PLAN_CAPABILITY_IDS = new Set(CAPABILITIES.map((capability) => capability.id));
|
|
229
|
+
const REQUIRED_PACK_IDS = ["agent_readiness", "agent_security", "safe_path_engine", "install_intake_risk", "workflow_efficiency", "frontend_readiness", "release_readiness", "source_backed_skills", "context_intelligence"];
|
|
230
|
+
const REQUIRED_PACK_FIELDS = [
|
|
231
|
+
"id",
|
|
232
|
+
"name",
|
|
233
|
+
"description",
|
|
234
|
+
"outcomes",
|
|
235
|
+
"capabilityIds",
|
|
236
|
+
"defaultEntitlement",
|
|
237
|
+
"recommendationSignals",
|
|
238
|
+
"statusCopy",
|
|
239
|
+
"dashboardCopy",
|
|
240
|
+
"userFacingCopy",
|
|
241
|
+
];
|
|
242
|
+
|
|
243
|
+
function validatePack(pack) {
|
|
244
|
+
const errors = [];
|
|
245
|
+
for (const field of REQUIRED_PACK_FIELDS) {
|
|
246
|
+
if (pack[field] === undefined || pack[field] === null) {
|
|
247
|
+
errors.push(`Missing required field: ${field}`);
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
if (!Array.isArray(pack.outcomes) || pack.outcomes.length === 0) {
|
|
251
|
+
errors.push("Pack must have at least one outcome");
|
|
252
|
+
}
|
|
253
|
+
if (!Array.isArray(pack.capabilityIds) || pack.capabilityIds.length === 0) {
|
|
254
|
+
errors.push("Pack must reference at least one capability ID");
|
|
255
|
+
} else {
|
|
256
|
+
const seenCapabilityIds = new Set();
|
|
257
|
+
pack.capabilityIds.forEach((capabilityId) => {
|
|
258
|
+
if (seenCapabilityIds.has(capabilityId)) {
|
|
259
|
+
errors.push(`Duplicate capability ID in pack: ${capabilityId}`);
|
|
260
|
+
}
|
|
261
|
+
seenCapabilityIds.add(capabilityId);
|
|
262
|
+
if (!PLAN_CAPABILITY_IDS.has(capabilityId) || !getPlanCapability(capabilityId)) {
|
|
263
|
+
errors.push(`Unknown capability ID: ${capabilityId}`);
|
|
264
|
+
}
|
|
265
|
+
});
|
|
266
|
+
}
|
|
267
|
+
if (!Array.isArray(pack.recommendationSignals) || pack.recommendationSignals.length === 0) {
|
|
268
|
+
errors.push("Pack.recommendationSignals must be a non-empty array");
|
|
269
|
+
}
|
|
270
|
+
return { valid: errors.length === 0, errors };
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
function validateAllPacks() {
|
|
274
|
+
const errors = [];
|
|
275
|
+
const seenIds = new Set();
|
|
276
|
+
|
|
277
|
+
for (const pack of CAPABILITY_PACKS) {
|
|
278
|
+
if (seenIds.has(pack.id)) {
|
|
279
|
+
errors.push(`Duplicate pack ID: ${pack.id}`);
|
|
280
|
+
}
|
|
281
|
+
seenIds.add(pack.id);
|
|
282
|
+
const result = validatePack(pack);
|
|
283
|
+
result.errors.forEach((error) => errors.push(`[${pack.id}] ${error}`));
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
for (const requiredId of REQUIRED_PACK_IDS) {
|
|
287
|
+
if (!seenIds.has(requiredId)) {
|
|
288
|
+
errors.push(`Required pack missing: ${requiredId}`);
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
return { valid: errors.length === 0, errors };
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
function getPack(id) {
|
|
296
|
+
return PACK_MAP.get(String(id || "").trim()) || null;
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
function listPacks() {
|
|
300
|
+
return Array.from(CAPABILITY_PACKS);
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
function getPacksForSignal(signal) {
|
|
304
|
+
return CAPABILITY_PACKS.filter((pack) => pack.recommendationSignals.includes(signal));
|
|
305
|
+
}
|
|
306
|
+
|
|
307
|
+
module.exports = {
|
|
308
|
+
CAPABILITY_PACKS,
|
|
309
|
+
validatePack,
|
|
310
|
+
validateAllPacks,
|
|
311
|
+
getPack,
|
|
312
|
+
listPacks,
|
|
313
|
+
getPacksForSignal,
|
|
314
|
+
};
|