@3lineas/grooveskills 1.5.0 → 1.7.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/README.md +8 -0
- package/dist/{chunk-PLMYUKGW.js → chunk-E63GTCOE.js} +475 -146
- package/dist/chunk-E63GTCOE.js.map +1 -0
- package/dist/cli.js +23 -3
- package/dist/cli.js.map +1 -1
- package/dist/main.js +1 -1
- package/package.json +3 -2
- package/skills/auth-rbac-policies/SKILL.md +100 -0
- package/skills/auth-rbac-policies/references/auth-adapters-examples.md +99 -0
- package/skills/caching-rate-limiting/SKILL.md +109 -0
- package/skills/caching-rate-limiting/references/cache-rate-limit-examples.md +129 -0
- package/skills/clean-architecture-ddd/SKILL.md +1 -0
- package/skills/controller-orchestration-queues/SKILL.md +109 -0
- package/skills/controller-orchestration-queues/references/controller-queue-examples.md +115 -0
- package/skills/docs-standards/SKILL.md +113 -0
- package/skills/docs-standards/references/adr-template-and-lifecycle.md +111 -0
- package/skills/docs-standards/references/code-comments-and-docstrings.md +147 -0
- package/skills/docs-standards/references/relative-paths-and-diagrams.md +123 -0
- package/skills/env-feature-flags/SKILL.md +94 -0
- package/skills/env-feature-flags/references/env-feature-flags-examples.md +93 -0
- package/skills/external-service-adapters/SKILL.md +148 -0
- package/skills/external-service-adapters/references/email-and-payment-examples.md +198 -0
- package/skills/storage-file-adapters/SKILL.md +125 -0
- package/skills/storage-file-adapters/references/storage-adapters-examples.md +164 -0
- package/skills/webhook-idempotency/SKILL.md +104 -0
- package/skills/webhook-idempotency/references/webhook-idempotency-examples.md +112 -0
- package/dist/chunk-PLMYUKGW.js.map +0 -1
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: webhook-idempotency
|
|
3
|
+
description: Standardized architectural pattern for incoming webhook verification and idempotency guards. Decouples vendor cryptographic signature checks (Stripe, MercadoPago, Svix, GitHub) into isolated adapters, and guarantees single execution via an IdempotencyGuard wrapper backed by persistent storage. TRIGGER when building webhook endpoints, handling payment callbacks, verifying HMAC signatures, or ensuring at-most-once processing.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Incoming Webhooks, Signature Verification & Idempotency Guards
|
|
7
|
+
|
|
8
|
+
Architectural pattern for incoming webhooks: decoupled cryptographic signature verification and atomic idempotency guards to protect against duplicate delivery and replay attacks.
|
|
9
|
+
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
## 1. The 3 Invariants of Secure Webhooks
|
|
13
|
+
|
|
14
|
+
1. **Verify Before Anything Else**:
|
|
15
|
+
- Webhook endpoints must verify HMAC cryptographic signatures using raw request bodies before running any business logic or parsing JSON.
|
|
16
|
+
2. **Idempotency Guard**:
|
|
17
|
+
- Webhooks are delivered with "at-least-once" guarantees. An `IdempotencyGuard` checks if an event ID was already processed; if so, returns early (HTTP 200) without re-running actions.
|
|
18
|
+
3. **Slim Webhook Controller**:
|
|
19
|
+
- The webhook controller verifies signatures, claims idempotency, and delegates to an action or dispatches to a queue.
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
## 2. Directory Layout
|
|
24
|
+
|
|
25
|
+
```text
|
|
26
|
+
src/
|
|
27
|
+
├── controllers/
|
|
28
|
+
│ └── webhooks/
|
|
29
|
+
│ ├── stripe-webhook.controller.ts # Verifies + Idempotency + Action (<80 lines)
|
|
30
|
+
│ └── mercadopago-webhook.controller.ts # Verifies + Idempotency + Action (<80 lines)
|
|
31
|
+
├── domains/
|
|
32
|
+
│ └── webhooks/
|
|
33
|
+
│ ├── webhook-verifier.port.ts # Signature verification interface (<40 lines)
|
|
34
|
+
│ └── idempotency.port.ts # Idempotency storage interface (<40 lines)
|
|
35
|
+
└── infrastructure/
|
|
36
|
+
├── adapters/
|
|
37
|
+
│ ├── webhooks/
|
|
38
|
+
│ │ ├── stripe-verifier.adapter.ts # Stripe signature verification (<70 lines)
|
|
39
|
+
│ │ ├── svix-verifier.adapter.ts # Svix HMAC verification (<70 lines)
|
|
40
|
+
│ │ └── mercadopago-verifier.adapter.ts # MP HMAC verification (<70 lines)
|
|
41
|
+
│ └── idempotency/
|
|
42
|
+
│ ├── redis-idempotency.adapter.ts # Redis SETNX implementation (<60 lines)
|
|
43
|
+
│ └── db-idempotency.adapter.ts # SQL unique constraint implementation (<60 lines)
|
|
44
|
+
└── guards/
|
|
45
|
+
└── idempotency.guard.ts # Idempotency execution wrapper (<70 lines)
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
---
|
|
49
|
+
|
|
50
|
+
## 3. Interfaces Contract (`src/domains/webhooks/`)
|
|
51
|
+
|
|
52
|
+
```ts
|
|
53
|
+
// webhook-verifier.port.ts
|
|
54
|
+
export interface WebhookVerifyInput {
|
|
55
|
+
rawBody: string | Uint8Array;
|
|
56
|
+
signatureHeader: string;
|
|
57
|
+
secret: string;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export interface WebhookVerifierPort<TEvent = unknown> {
|
|
61
|
+
verify(input: WebhookVerifyInput): Promise<TEvent>;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
// idempotency.port.ts
|
|
65
|
+
export interface IdempotencyPort {
|
|
66
|
+
lockOrSkip(key: string, ttlSeconds: number): Promise<boolean>;
|
|
67
|
+
markCompleted(key: string): Promise<void>;
|
|
68
|
+
}
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
---
|
|
72
|
+
|
|
73
|
+
## 4. Idempotency Guard Implementation
|
|
74
|
+
|
|
75
|
+
```ts
|
|
76
|
+
// src/infrastructure/guards/idempotency.guard.ts
|
|
77
|
+
import type { IdempotencyPort } from "@/domains/webhooks/idempotency.port";
|
|
78
|
+
|
|
79
|
+
export class IdempotencyGuard {
|
|
80
|
+
constructor(private port: IdempotencyPort) {}
|
|
81
|
+
|
|
82
|
+
async runOnce<T>(key: string, ttlSeconds: number, fn: () => Promise<T>): Promise<{ executed: boolean; result?: T }> {
|
|
83
|
+
const acquired = await this.port.lockOrSkip(key, ttlSeconds);
|
|
84
|
+
if (!acquired) {
|
|
85
|
+
return { executed: false };
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
try {
|
|
89
|
+
const result = await fn();
|
|
90
|
+
await this.port.markCompleted(key);
|
|
91
|
+
return { executed: true, result };
|
|
92
|
+
} catch (err) {
|
|
93
|
+
throw err;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
---
|
|
100
|
+
|
|
101
|
+
## 5. Detailed Verifiers & Store References
|
|
102
|
+
|
|
103
|
+
For real HMAC verifiers (Stripe, Svix, MercadoPago) and Redis/SQL idempotency stores, see:
|
|
104
|
+
- `references/webhook-idempotency-examples.md`
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
# Implementation Reference: Webhook Verifiers & Idempotency Stores
|
|
2
|
+
|
|
3
|
+
Real-world HMAC verification adapters (Stripe, Svix, MercadoPago) and atomic idempotency stores (Redis, SQL).
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## 1. Stripe Webhook Verifier Adapter
|
|
8
|
+
|
|
9
|
+
```ts
|
|
10
|
+
// src/infrastructure/adapters/webhooks/stripe-verifier.adapter.ts
|
|
11
|
+
import Stripe from "stripe";
|
|
12
|
+
import type { WebhookVerifierPort, WebhookVerifyInput } from "@/domains/webhooks/webhook-verifier.port";
|
|
13
|
+
import { AppError } from "@/errors/app-error";
|
|
14
|
+
|
|
15
|
+
export class StripeWebhookVerifierAdapter implements WebhookVerifierPort<Stripe.Event> {
|
|
16
|
+
constructor(private stripe: Stripe) {}
|
|
17
|
+
|
|
18
|
+
async verify(input: WebhookVerifyInput): Promise<Stripe.Event> {
|
|
19
|
+
try {
|
|
20
|
+
return this.stripe.webhooks.constructEvent(
|
|
21
|
+
input.rawBody,
|
|
22
|
+
input.signatureHeader,
|
|
23
|
+
input.secret
|
|
24
|
+
);
|
|
25
|
+
} catch (err) {
|
|
26
|
+
throw new AppError({
|
|
27
|
+
message: "Firma criptográfica de Stripe inválida.",
|
|
28
|
+
statusCode: 400,
|
|
29
|
+
cause: err,
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
## 2. Svix Webhook Verifier Adapter
|
|
39
|
+
|
|
40
|
+
```ts
|
|
41
|
+
// src/infrastructure/adapters/webhooks/svix-verifier.adapter.ts
|
|
42
|
+
import { Webhook } from "svix";
|
|
43
|
+
import type { WebhookVerifierPort, WebhookVerifyInput } from "@/domains/webhooks/webhook-verifier.port";
|
|
44
|
+
import { AppError } from "@/errors/app-error";
|
|
45
|
+
|
|
46
|
+
export class SvixWebhookVerifierAdapter implements WebhookVerifierPort<unknown> {
|
|
47
|
+
async verify(input: WebhookVerifyInput): Promise<unknown> {
|
|
48
|
+
try {
|
|
49
|
+
const wh = new Webhook(input.secret);
|
|
50
|
+
return wh.verify(input.rawBody.toString(), { "svix-signature": input.signatureHeader });
|
|
51
|
+
} catch (err) {
|
|
52
|
+
throw new AppError({ message: "Firma Svix inválida.", statusCode: 400, cause: err });
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
---
|
|
59
|
+
|
|
60
|
+
## 3. Redis Idempotency Store (`SET key NX EX`)
|
|
61
|
+
|
|
62
|
+
```ts
|
|
63
|
+
// src/infrastructure/adapters/idempotency/redis-idempotency.adapter.ts
|
|
64
|
+
import type { Redis } from "ioredis";
|
|
65
|
+
import type { IdempotencyPort } from "@/domains/webhooks/idempotency.port";
|
|
66
|
+
|
|
67
|
+
export class RedisIdempotencyAdapter implements IdempotencyPort {
|
|
68
|
+
constructor(private redis: Redis) {}
|
|
69
|
+
|
|
70
|
+
async lockOrSkip(key: string, ttlSeconds: number): Promise<boolean> {
|
|
71
|
+
const res = await this.redis.set(`idemp:${key}`, "processing", "EX", ttlSeconds, "NX");
|
|
72
|
+
return res === "OK";
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
async markCompleted(key: string): Promise<void> {
|
|
76
|
+
await this.redis.set(`idemp:${key}`, "completed", "KEEPTTL");
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
## 4. End-to-End Webhook Controller with Idempotency
|
|
84
|
+
|
|
85
|
+
```ts
|
|
86
|
+
// src/controllers/webhooks/stripe-webhook.controller.ts
|
|
87
|
+
import type { Context } from "hono";
|
|
88
|
+
import type { WebhookVerifierPort } from "@/domains/webhooks/webhook-verifier.port";
|
|
89
|
+
import type { IdempotencyGuard } from "@/infrastructure/guards/idempotency.guard";
|
|
90
|
+
import { fulfillSubscriptionAction } from "@/actions/billing/fulfill-subscription.action";
|
|
91
|
+
import type Stripe from "stripe";
|
|
92
|
+
|
|
93
|
+
export async function stripeWebhookController(
|
|
94
|
+
c: Context,
|
|
95
|
+
verifier: WebhookVerifierPort<Stripe.Event>,
|
|
96
|
+
guard: IdempotencyGuard,
|
|
97
|
+
webhookSecret: string
|
|
98
|
+
) {
|
|
99
|
+
const signature = c.req.header("stripe-signature") ?? "";
|
|
100
|
+
const rawBody = await c.req.text();
|
|
101
|
+
|
|
102
|
+
const event = await verifier.verify({ rawBody, signatureHeader: signature, secret: webhookSecret });
|
|
103
|
+
|
|
104
|
+
const { executed } = await guard.runOnce(event.id, 86400, async () => {
|
|
105
|
+
if (event.type === "checkout.session.completed") {
|
|
106
|
+
await fulfillSubscriptionAction(event.data.object as Stripe.Checkout.Session);
|
|
107
|
+
}
|
|
108
|
+
});
|
|
109
|
+
|
|
110
|
+
return c.json({ received: true, processed: executed }, 200);
|
|
111
|
+
}
|
|
112
|
+
```
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/domains/detector/project-detector.ts","../src/domains/detector/detect-agents.ts","../src/domains/detector/detect-dependencies.ts","../src/domains/registry/skill-catalog.ts","../src/domains/ui/ui-orchestrator.ts","../src/domains/ui/banners.ts","../src/domains/ui/prompt-skills.ts","../src/domains/ui/prompt-agents.ts","../src/domains/ui/prompt-language.ts","../src/domains/ui/prompt-confirm-overwrite.ts","../src/domains/installer/verify-skill-exists.ts","../src/domains/installer/install-orchestrator.ts","../src/domains/adapters/skill-reference-builder.ts","../src/domains/project-store/project-paths.ts","../src/domains/adapters/antigravity.adapter.ts","../src/domains/adapters/claude.adapter.ts","../src/domains/adapters/cursor.adapter.ts","../src/domains/adapters/gemini.adapter.ts","../src/domains/project-store/sync-project-store.ts","../src/domains/installer/resolve-skills-source.ts","../src/domains/harness/install-harness.ts","../src/domains/harness/harness-languages.ts","../src/domains/harness/harness-templates.ts","../src/domains/harness/scan-project-onboarding.ts","../src/domains/harness/upsert-agent-instructions.ts","../src/domains/harness/write-project-config.ts","../src/main.ts"],"sourcesContent":["import { existsSync, readFileSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { detectAgents } from \"@/domains/detector/detect-agents\";\nimport { detectDependencies } from \"@/domains/detector/detect-dependencies\";\nimport { SKILL_CATALOG } from \"@/domains/registry/skill-catalog\";\nimport type { ProjectContext } from \"@/types/context.types\";\nimport type { GrooveSkillsConfig, ProjectLanguage } from \"@/types/harness.types\";\n\nfunction readConfiguredLanguage(targetPath: string): ProjectLanguage | undefined {\n const configPath = join(targetPath, \".grooveskills\", \"config.json\");\n if (!existsSync(configPath)) {\n return undefined;\n }\n\n try {\n const raw = readFileSync(configPath, \"utf-8\");\n const parsed = JSON.parse(raw) as Partial<GrooveSkillsConfig>;\n return typeof parsed.language === \"string\" ? (parsed.language as ProjectLanguage) : undefined;\n } catch {\n return undefined;\n }\n}\n\nexport function detectProjectContext(targetPath: string): ProjectContext {\n const detectedAgents = detectAgents(targetPath);\n const { dependencies, exists } = detectDependencies(targetPath);\n\n const suggestedSkillIds: string[] = [\n \"odd-ai\",\n \"best-practices\",\n \"ux-writing\",\n \"error-handling-logging\",\n \"clean-architecture-ddd\",\n ];\n\n for (const skill of SKILL_CATALOG) {\n if (skill.dependencies.length === 0) {\n continue;\n }\n const hasMatch = skill.dependencies.some((dep) => dependencies.includes(dep));\n if (hasMatch && !suggestedSkillIds.includes(skill.id)) {\n suggestedSkillIds.push(skill.id);\n }\n }\n\n const harnessExists = existsSync(join(targetPath, \".grooveskills\", \"memory\", \"context.md\"));\n const configuredLanguage = readConfiguredLanguage(targetPath);\n\n return {\n targetPath,\n detectedDependencies: dependencies,\n suggestedSkillIds,\n detectedAgents,\n packageJsonExists: exists,\n harnessExists,\n configuredLanguage,\n };\n}\n","import { readdirSync } from \"node:fs\";\nimport type { AgentId } from \"@/types/agent.types\";\n\nexport function detectAgents(targetPath: string): AgentId[] {\n const detected: AgentId[] = [];\n\n try {\n const entries = new Set(readdirSync(targetPath));\n\n if (entries.has(\".agents\")) {\n detected.push(\"antigravity\");\n }\n if (entries.has(\".claude\")) {\n detected.push(\"claude\");\n }\n if (entries.has(\".cursor\")) {\n detected.push(\"cursor\");\n }\n if (entries.has(\".gemini\")) {\n detected.push(\"gemini\");\n }\n } catch {\n // If directory cannot be read, return empty list gracefully\n }\n\n return detected;\n}\n","import { readFileSync, existsSync } from \"node:fs\";\nimport { join } from \"node:path\";\n\nexport interface PackageJsonDetection {\n dependencies: string[];\n exists: boolean;\n}\n\nexport function detectDependencies(targetPath: string): PackageJsonDetection {\n const detected = new Set<string>();\n let hasManifest = false;\n\n const packageJsonPath = join(targetPath, \"package.json\");\n if (existsSync(packageJsonPath)) {\n hasManifest = true;\n try {\n const raw = readFileSync(packageJsonPath, \"utf-8\");\n const parsed = JSON.parse(raw) as {\n dependencies?: Record<string, string>;\n devDependencies?: Record<string, string>;\n };\n\n for (const dep of Object.keys(parsed.dependencies ?? {})) {\n detected.add(dep);\n }\n for (const dep of Object.keys(parsed.devDependencies ?? {})) {\n detected.add(dep);\n }\n } catch {\n // Ignore JSON parse errors gracefully\n }\n }\n\n const cargoPath = join(targetPath, \"Cargo.toml\");\n if (existsSync(cargoPath)) {\n hasManifest = true;\n detected.add(\"rust\");\n }\n\n const pyprojectPath = join(targetPath, \"pyproject.toml\");\n const requirementsPath = join(targetPath, \"requirements.txt\");\n if (existsSync(pyprojectPath) || existsSync(requirementsPath)) {\n hasManifest = true;\n detected.add(\"python\");\n }\n\n return {\n dependencies: Array.from(detected),\n exists: hasManifest,\n };\n}\n","import type { SkillMetadata } from \"@/types/skill.types\";\n\nexport const SKILL_CATALOG: SkillMetadata[] = [\n {\n id: \"groove-harness\",\n name: \"GrooveSkills Harness\",\n description: \"Lightweight project harness, context memory, and ODD 3-lane task execution (Answer, Task, Spec) for AI coding agents\",\n dependencies: [],\n directoryName: \"groove-harness\",\n isCoreHarness: true,\n },\n {\n id: \"odd-ai\",\n name: \"Organic & Outcome-Driven Development (ODD)\",\n description: \"7-step ODD protocol for AI agents: authorize, explore, classify, outcome hypotheses, and verifiable evidence receipts\",\n dependencies: [],\n directoryName: \"odd-ai\",\n },\n {\n id: \"best-practices\",\n name: \"Universal Best Practices\",\n description: \"Multi-language clean code standards, early returns, no barrel files, strict typing, <200 lines\",\n dependencies: [],\n directoryName: \"best-practices\",\n },\n {\n id: \"ux-writing\",\n name: \"UX Writing & Microcopy Standards\",\n description: \"Persuasive, empathetic, professional bilingual microcopy (ES/EN) for error messages, forms, CTAs, toasts, and empty states\",\n dependencies: [],\n directoryName: \"ux-writing\",\n },\n {\n id: \"typescript-clean\",\n name: \"TypeScript Clean Code (TS 5.5+)\",\n description: \"Advanced strict TypeScript, discriminated unions, satisfies, const generics, unknown over any, and zero unsafe casts\",\n dependencies: [\"typescript\"],\n directoryName: \"typescript-clean\",\n },\n {\n id: \"rust-clean\",\n name: \"Rust Clean Code (Rust 2024)\",\n description: \"Idiomatic Rust clean code: let-else guard clauses, no unwrap in production, thiserror typed errors, Newtypes, zero barrel files, <200 lines\",\n dependencies: [\"rust\"],\n directoryName: \"rust-clean\",\n },\n {\n id: \"python-clean\",\n name: \"Python Clean Code (Python 3.12+)\",\n description: \"Modern Python standards: guard clauses (no nested ifs), strict typing (zero Any), uv, Ruff, Pyright, Pydantic v2 boundaries, <200 lines\",\n dependencies: [\"python\"],\n directoryName: \"python-clean\",\n },\n {\n id: \"error-handling-logging\",\n name: \"Error Handling & Structured Logging\",\n description: \"Deterministic error management with AppError, Result/ActionResponse contracts, and structured context logging\",\n dependencies: [],\n directoryName: \"error-handling-logging\",\n },\n {\n id: \"valibot-validation\",\n name: \"Valibot Schema Validation\",\n description: \"Boundary schema validation with Valibot (* as v from 'valibot'), strict type inference, and friendly error messages\",\n dependencies: [\"valibot\"],\n directoryName: \"valibot-validation\",\n },\n {\n id: \"clean-architecture-ddd\",\n name: \"Clean Architecture & DDD\",\n description: \"Domain-driven design, isolated single-purpose Actions, pure functions, immutability, zero barrel files, <200 lines per file\",\n dependencies: [],\n directoryName: \"clean-architecture-ddd\",\n },\n {\n id: \"testing-vitest\",\n name: \"Vitest Testing Standards\",\n description: \"Clean unit and integration testing with Vitest: AAA pattern, behavioral testing over mocks, and boundary edge cases\",\n dependencies: [\"vitest\"],\n directoryName: \"testing-vitest\",\n },\n {\n id: \"hono\",\n name: \"Hono Architecture (Valibot)\",\n description: \"Enterprise Hono API standard with Valibot validation, isolated Actions layer, and RPC bindings\",\n dependencies: [\"hono\", \"@hono/valibot-validator\", \"@hono/standard-validator\"],\n directoryName: \"hono\",\n },\n {\n id: \"react-core\",\n name: \"React Core Fundamentals\",\n description: \"Opinionated React fundamentals: function components, JSX, immutable state, core hooks, lists, and controlled inputs\",\n dependencies: [\"react\", \"react-dom\"],\n directoryName: \"react-core\",\n },\n {\n id: \"react-advanced\",\n name: \"React 19 Advanced & Compiler Architecture\",\n description: \"Modern React 19 platform features: React Compiler auto-memoization, concurrent rendering, use(), Actions, virtualization, and RSC boundaries\",\n dependencies: [\"react\", \"react-dom\"],\n directoryName: \"react-advanced\",\n },\n {\n id: \"react-create-page\",\n name: \"React Page & View Architecture\",\n description: \"Clean architecture for React pages: declarative page coordinators, domain hooks, isolated API actions, Valibot + Formisch forms, and atomic co-location\",\n dependencies: [\"react\", \"react-dom\"],\n directoryName: \"react-create-page\",\n },\n];\n","import * as p from \"@clack/prompts\";\nimport pc from \"picocolors\";\nimport { renderBanner } from \"@/domains/ui/banners\";\nimport { promptSkills } from \"@/domains/ui/prompt-skills\";\nimport { promptAgents } from \"@/domains/ui/prompt-agents\";\nimport { promptLanguage } from \"@/domains/ui/prompt-language\";\nimport { promptConfirmOverwrite } from \"@/domains/ui/prompt-confirm-overwrite\";\nimport { verifySkillExists } from \"@/domains/installer/verify-skill-exists\";\nimport { installSkills } from \"@/domains/installer/install-orchestrator\";\nimport { SKILL_CATALOG } from \"@/domains/registry/skill-catalog\";\nimport type { ProjectContext } from \"@/types/context.types\";\nimport type { AgentId } from \"@/types/agent.types\";\nimport type { ProjectLanguage } from \"@/types/harness.types\";\n\nasync function resolveLanguageSelection(\n harnessExists: boolean,\n configuredLanguage?: ProjectLanguage,\n forceOnboarding?: boolean\n): Promise<ProjectLanguage> {\n if (harnessExists && !forceOnboarding) {\n return configuredLanguage ?? \"es\";\n }\n\n const langChoice = await promptLanguage(configuredLanguage ?? \"es\");\n if (p.isCancel(langChoice)) {\n p.cancel(\"Installation cancelled. Have a wonderful day!\");\n process.exit(0);\n }\n\n return langChoice as ProjectLanguage;\n}\n\nasync function resolveOverwriteConfirmation(\n targetPath: string,\n selectedSkills: string[],\n selectedAgents: AgentId[]\n): Promise<boolean> {\n const anyExists = selectedSkills.some((skillId) => {\n const meta = SKILL_CATALOG.find((s) => s.id === skillId);\n return meta ? verifySkillExists(targetPath, meta.directoryName, selectedAgents) : false;\n });\n\n if (!anyExists) {\n return true;\n }\n\n const confirm = await promptConfirmOverwrite();\n if (p.isCancel(confirm) || !confirm) {\n p.cancel(\"Installation stopped to protect existing skills.\");\n process.exit(0);\n }\n\n return Boolean(confirm);\n}\n\nexport async function runInteractiveUi(\n context: ProjectContext,\n forceOnboarding: boolean = false\n): Promise<void> {\n console.log(renderBanner());\n p.intro(pc.magenta(\"Welcome to GrooveSkills! Let's tailor your AI agents with clean architectural standards.\"));\n\n if (context.detectedDependencies.length > 0) {\n const harnessInfo = context.harnessExists && !forceOnboarding\n ? pc.green(`Active (.grooveskills/memory, lang: ${context.configuredLanguage ?? \"es\"})`)\n : pc.cyan(\"Will be initialized\");\n\n p.note(\n `Detected dependencies: ${context.detectedDependencies.map((d) => pc.bold(d)).join(\", \")}\\n` +\n `Active AI folders: ${context.detectedAgents.map((a) => pc.green(a)).join(\", \") || \"None (will be created)\"}\\n` +\n `GrooveSkills Harness: ${harnessInfo}`,\n \"Project Environment\"\n );\n }\n\n const selectedSkills = await promptSkills(context.suggestedSkillIds);\n if (p.isCancel(selectedSkills)) {\n p.cancel(\"Installation cancelled. Have a wonderful day!\");\n process.exit(0);\n }\n\n const selectedAgents = await promptAgents(context.detectedAgents);\n if (p.isCancel(selectedAgents)) {\n p.cancel(\"Installation cancelled. Have a wonderful day!\");\n process.exit(0);\n }\n\n const selectedLanguage = await resolveLanguageSelection(\n context.harnessExists,\n context.configuredLanguage,\n forceOnboarding\n );\n\n const forceOverwrite = await resolveOverwriteConfirmation(\n context.targetPath,\n selectedSkills as string[],\n selectedAgents as AgentId[]\n );\n\n const s = p.spinner();\n s.start(\"Installing and adapting skills across your configured AI agents...\");\n\n const result = await installSkills({\n targetPath: context.targetPath,\n selectedSkillIds: selectedSkills as string[],\n selectedAgents: selectedAgents as AgentId[],\n forceOverwrite,\n enableHarness: true,\n detectedDependencies: context.detectedDependencies,\n language: selectedLanguage,\n forceOnboarding,\n });\n\n s.stop(pc.green(\"All skills and harness have been successfully configured!\"));\n\n const harnessStatus = result.harnessInitialized\n ? pc.green(`Initialized in .grooveskills/ (Language: ${selectedLanguage})`)\n : pc.cyan(`Preserved in .grooveskills/ (Language: ${selectedLanguage})`);\n\n p.note(\n `Configured skills: ${result.installedSkills.map((s) => pc.bold(s)).join(\", \")}\\n` +\n `Target agents: ${result.configuredAgents.map((a) => pc.cyan(a)).join(\", \")}\\n` +\n `GrooveSkills Harness: ${harnessStatus}`,\n \"Installation Summary\"\n );\n\n p.outro(pc.green(\"Your AI programming pair is now empowered with your team's architectural habits! 🚀\"));\n}\n","import pc from \"picocolors\";\n\nexport function renderBanner(): string {\n const title = pc.bold(pc.white(\" GROOVE SKILLS \"));\n const badge = pc.bgMagenta(pc.black(title));\n const subtitle = pc.dim(\"Multi-Agent AI Skills & Architectural Standards\");\n\n return `${badge} ${subtitle}\\n`;\n}\n","import * as p from \"@clack/prompts\";\nimport { SKILL_CATALOG } from \"@/domains/registry/skill-catalog\";\n\nexport async function promptSkills(suggestedSkillIds: string[]): Promise<string[] | symbol> {\n const selectableSkills = SKILL_CATALOG.filter((skill) => !skill.isCoreHarness);\n const options = selectableSkills.map((skill) => {\n const isSuggested = suggestedSkillIds.includes(skill.id);\n return {\n value: skill.id,\n label: skill.name,\n hint: isSuggested ? \"Suggested based on your project stack\" : skill.description,\n };\n });\n\n const selected = await p.multiselect({\n message: \"Which skills would you like to install in this project?\",\n options,\n initialValues: suggestedSkillIds,\n required: true,\n });\n\n return selected;\n}\n","import * as p from \"@clack/prompts\";\nimport type { AgentId } from \"@/types/agent.types\";\n\nexport async function promptAgents(detectedAgents: AgentId[]): Promise<AgentId[] | symbol> {\n const options: Array<{ value: AgentId; label: string; hint: string }> = [\n { value: \"antigravity\", label: \"Antigravity\", hint: \".agents/skills (Google Agentic IDE)\" },\n { value: \"claude\", label: \"Claude Code\", hint: \".claude/skills (Anthropic Claude Code)\" },\n { value: \"cursor\", label: \"Cursor\", hint: \".cursor/rules/*.mdc (Cursor IDE Rules)\" },\n { value: \"gemini\", label: \"Gemini Code Assist\", hint: \".gemini/skills (Google Gemini)\" },\n ];\n\n const initialValues: AgentId[] = detectedAgents.length > 0 ? detectedAgents : [\"antigravity\"];\n\n const selected = await p.multiselect({\n message: \"Which AI agents should be configured?\",\n options,\n initialValues,\n required: true,\n });\n\n return selected as AgentId[] | symbol;\n}\n","import * as p from \"@clack/prompts\";\nimport type { ProjectLanguage } from \"@/types/harness.types\";\n\nexport async function promptLanguage(defaultLanguage: ProjectLanguage = \"es\"): Promise<ProjectLanguage | symbol> {\n const options = [\n { value: \"es\", label: \"Español (Spanish)\", hint: \"Recomendado para proyectos en español\" },\n { value: \"en\", label: \"English\", hint: \"Standard international English\" },\n { value: \"pt\", label: \"Português (Portuguese)\", hint: \"Português para o Brasil e Portugal\" },\n { value: \"it\", label: \"Italiano (Italian)\", hint: \"Comunicazione in lingua italiana\" },\n { value: \"fr\", label: \"Français (French)\", hint: \"Communication en langue française\" },\n ];\n\n const selected = await p.select({\n message: \"Which language should AI agents use for user-facing copy and communication?\",\n options,\n initialValue: defaultLanguage,\n });\n\n return selected as ProjectLanguage | symbol;\n}\n","import * as p from \"@clack/prompts\";\n\nexport async function promptConfirmOverwrite(): Promise<boolean | symbol> {\n return await p.confirm({\n message: \"Some skills already exist in this project. Would you like to overwrite them with the latest version?\",\n initialValue: true,\n });\n}\n","import { lstatSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport type { AgentId } from \"@/types/agent.types\";\n\nconst AGENT_DESTINATION_MAP: Record<AgentId, (dir: string) => string> = {\n antigravity: (dir) => join(\".agents\", \"skills\", dir),\n claude: (dir) => join(\".claude\", \"skills\", dir),\n cursor: (dir) => join(\".cursor\", \"rules\", `${dir}.mdc`),\n gemini: (dir) => join(\".gemini\", \"skills\", dir),\n};\n\nexport function verifySkillExists(\n targetPath: string,\n skillDirectoryName: string,\n agents: AgentId[]\n): boolean {\n for (const agent of agents) {\n const relativePathResolver = AGENT_DESTINATION_MAP[agent];\n const destination = join(targetPath, relativePathResolver(skillDirectoryName));\n\n try {\n lstatSync(destination);\n return true;\n } catch {\n // Path does not exist\n }\n }\n\n return false;\n}\n","import { join } from \"node:path\";\nimport { AntigravityAdapter } from \"@/domains/adapters/antigravity.adapter\";\nimport { ClaudeAdapter } from \"@/domains/adapters/claude.adapter\";\nimport { CursorAdapter } from \"@/domains/adapters/cursor.adapter\";\nimport { GeminiAdapter } from \"@/domains/adapters/gemini.adapter\";\nimport { syncProjectStore } from \"@/domains/project-store/sync-project-store\";\nimport { getProjectSkillsDir } from \"@/domains/project-store/project-paths\";\nimport { installHarness } from \"@/domains/harness/install-harness\";\nimport { writeProjectConfig } from \"@/domains/harness/write-project-config\";\nimport { SKILL_CATALOG } from \"@/domains/registry/skill-catalog\";\nimport type { AgentAdapter } from \"@/domains/adapters/adapter.interface\";\nimport type { InstallOptions, InstallResult } from \"@/types/installer.types\";\nimport type { AgentId } from \"@/types/agent.types\";\n\nconst ADAPTER_REGISTRY: Record<AgentId, AgentAdapter> = {\n antigravity: new AntigravityAdapter(),\n claude: new ClaudeAdapter(),\n cursor: new CursorAdapter(),\n gemini: new GeminiAdapter(),\n};\n\nexport async function installSkills(options: InstallOptions): Promise<InstallResult> {\n const skillsToInstall = [...options.selectedSkillIds];\n\n if (!skillsToInstall.includes(\"groove-harness\")) {\n skillsToInstall.push(\"groove-harness\");\n }\n\n if (!skillsToInstall.includes(\"odd-ai\")) {\n skillsToInstall.push(\"odd-ai\");\n }\n\n syncProjectStore(options.targetPath, skillsToInstall, options.selectedAgents);\n\n const projectSkillsDir = getProjectSkillsDir(options.targetPath);\n const createdFiles: string[] = [];\n\n for (const skillId of skillsToInstall) {\n const skill = SKILL_CATALOG.find((item) => item.id === skillId);\n if (!skill) {\n continue;\n }\n\n const skillSourceDir = join(projectSkillsDir, skill.directoryName);\n\n for (const agentId of options.selectedAgents) {\n const adapter = ADAPTER_REGISTRY[agentId];\n if (!adapter) {\n continue;\n }\n\n const files = await adapter.installSkill(options.targetPath, skill, skillSourceDir);\n createdFiles.push(...files);\n }\n }\n\n const harnessFiles = installHarness({\n targetPath: options.targetPath,\n selectedAgents: options.selectedAgents,\n selectedSkillIds: skillsToInstall,\n detectedDependencies: options.detectedDependencies || [],\n language: options.language,\n forceOnboarding: options.forceOnboarding,\n });\n createdFiles.push(...harnessFiles);\n\n const configPath = writeProjectConfig(\n options.targetPath,\n skillsToInstall,\n options.selectedAgents,\n true,\n options.language\n );\n createdFiles.push(configPath);\n\n return {\n installedSkills: skillsToInstall,\n configuredAgents: options.selectedAgents,\n createdFiles,\n harnessInitialized: true,\n language: options.language,\n };\n}\n","import { existsSync, lstatSync, mkdirSync, readFileSync, rmSync, unlinkSync, writeFileSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { getProjectSkillsDir } from \"@/domains/project-store/project-paths\";\nimport type { SkillMetadata } from \"@/types/skill.types\";\n\nfunction removeExistingPathSafely(path: string): void {\n const fileExists = existsSync(path);\n\n if (!fileExists) {\n try {\n const lstat = lstatSync(path);\n if (lstat.isSymbolicLink()) {\n unlinkSync(path);\n }\n } catch {\n // Ignored if file really does not exist\n }\n return;\n }\n\n try {\n const lstat = lstatSync(path);\n if (lstat.isSymbolicLink()) {\n unlinkSync(path);\n return;\n }\n\n if (lstat.isDirectory()) {\n rmSync(path, { recursive: true, force: true });\n return;\n }\n\n unlinkSync(path);\n } catch {\n // Graceful fallback\n }\n}\n\nfunction extractSkillDescription(canonicalSkillMdPath: string, fallback: string): string {\n if (!existsSync(canonicalSkillMdPath)) {\n return fallback;\n }\n\n try {\n const content = readFileSync(canonicalSkillMdPath, \"utf-8\");\n const match = content.match(/^description:\\s*(.+)$/m);\n const hasMatchedDesc = Boolean(match && match[1]);\n if (hasMatchedDesc && match?.[1]) {\n return match[1].trim();\n }\n } catch {\n // Use fallback on error\n }\n\n return fallback;\n}\n\nexport function writeAgentSkillReference(\n targetPath: string,\n agentRelativeSkillsDir: string,\n skill: SkillMetadata\n): string {\n const agentSkillFolder = join(targetPath, agentRelativeSkillsDir, skill.directoryName);\n removeExistingPathSafely(agentSkillFolder);\n\n mkdirSync(agentSkillFolder, { recursive: true });\n\n const canonicalSkillMd = join(getProjectSkillsDir(targetPath), skill.directoryName, \"SKILL.md\");\n const description = extractSkillDescription(canonicalSkillMd, skill.description);\n\n const referenceContent = `---\nname: ${skill.id}\ndescription: ${description}\n---\n\n# ${skill.name} — Skill Reference\n\nCanonical skill specification stored in \\`.grooveskills/\\`.\n\n- **Specification**: [\\`.grooveskills/skills/${skill.directoryName}/SKILL.md\\`](../../../.grooveskills/skills/${skill.directoryName}/SKILL.md)\n- **References & Templates**: \\`.grooveskills/skills/${skill.directoryName}/\\`\n\n> **Instruction**: Read \\`.grooveskills/skills/${skill.directoryName}/SKILL.md\\` before executing tasks matching this skill.\n`;\n\n const targetFile = join(agentSkillFolder, \"SKILL.md\");\n writeFileSync(targetFile, referenceContent, \"utf-8\");\n\n return targetFile;\n}\n\nexport function writeCursorRuleReference(\n targetPath: string,\n cursorRelativeRulesDir: string,\n skill: SkillMetadata\n): string {\n const rulesDir = join(targetPath, cursorRelativeRulesDir);\n if (!existsSync(rulesDir)) {\n mkdirSync(rulesDir, { recursive: true });\n }\n\n const targetFile = join(rulesDir, `${skill.id}.mdc`);\n removeExistingPathSafely(targetFile);\n\n const canonicalSkillMd = join(getProjectSkillsDir(targetPath), skill.directoryName, \"SKILL.md\");\n const description = extractSkillDescription(canonicalSkillMd, skill.description);\n\n const referenceContent = `---\ndescription: ${description}\nglobs: [\"**/*\"]\nalwaysApply: false\n---\n\n# ${skill.name} — Rule Reference\n\nCanonical rule specification stored in \\`.grooveskills/\\`.\n\n- **Specification**: \\`.grooveskills/skills/${skill.directoryName}/SKILL.md\\`\n- **References & Templates**: \\`.grooveskills/skills/${skill.directoryName}/\\`\n\n> **Instruction**: Read \\`.grooveskills/skills/${skill.directoryName}/SKILL.md\\` before executing tasks matching this rule.\n`;\n\n writeFileSync(targetFile, referenceContent, \"utf-8\");\n\n return targetFile;\n}\n","import { join } from \"node:path\";\n\nexport function getProjectStoreDir(targetPath: string): string {\n return join(targetPath, \".grooveskills\");\n}\n\nexport function getProjectSkillsDir(targetPath: string): string {\n return join(getProjectStoreDir(targetPath), \"skills\");\n}\n\nexport function getProjectMemoryDir(targetPath: string): string {\n return join(getProjectStoreDir(targetPath), \"memory\");\n}\n\nexport function getProjectTasksDir(targetPath: string): string {\n return join(getProjectMemoryDir(targetPath), \"tasks\");\n}\n\nexport function getProjectConfigPath(targetPath: string): string {\n return join(getProjectStoreDir(targetPath), \"config.json\");\n}\n","import type { AgentAdapter } from \"@/domains/adapters/adapter.interface\";\nimport { writeAgentSkillReference } from \"@/domains/adapters/skill-reference-builder\";\nimport type { SkillMetadata } from \"@/types/skill.types\";\n\nexport class AntigravityAdapter implements AgentAdapter {\n readonly id = \"antigravity\" as const;\n readonly name = \"Antigravity\";\n readonly targetRelativeDir = \".agents/skills\";\n\n async installSkill(\n targetPath: string,\n skill: SkillMetadata,\n _skillSourceDir: string\n ): Promise<string[]> {\n const file = writeAgentSkillReference(targetPath, this.targetRelativeDir, skill);\n return [file];\n }\n}\n","import type { AgentAdapter } from \"@/domains/adapters/adapter.interface\";\nimport { writeAgentSkillReference } from \"@/domains/adapters/skill-reference-builder\";\nimport type { SkillMetadata } from \"@/types/skill.types\";\n\nexport class ClaudeAdapter implements AgentAdapter {\n readonly id = \"claude\" as const;\n readonly name = \"Claude Code\";\n readonly targetRelativeDir = \".claude/skills\";\n\n async installSkill(\n targetPath: string,\n skill: SkillMetadata,\n _skillSourceDir: string\n ): Promise<string[]> {\n const file = writeAgentSkillReference(targetPath, this.targetRelativeDir, skill);\n return [file];\n }\n}\n","import type { AgentAdapter } from \"@/domains/adapters/adapter.interface\";\nimport { writeCursorRuleReference } from \"@/domains/adapters/skill-reference-builder\";\nimport type { SkillMetadata } from \"@/types/skill.types\";\n\nexport class CursorAdapter implements AgentAdapter {\n readonly id = \"cursor\" as const;\n readonly name = \"Cursor\";\n readonly targetRelativeDir = \".cursor/rules\";\n\n async installSkill(\n targetPath: string,\n skill: SkillMetadata,\n _skillSourceDir: string\n ): Promise<string[]> {\n const file = writeCursorRuleReference(targetPath, this.targetRelativeDir, skill);\n return [file];\n }\n}\n","import type { AgentAdapter } from \"@/domains/adapters/adapter.interface\";\nimport { writeAgentSkillReference } from \"@/domains/adapters/skill-reference-builder\";\nimport type { SkillMetadata } from \"@/types/skill.types\";\n\nexport class GeminiAdapter implements AgentAdapter {\n readonly id = \"gemini\" as const;\n readonly name = \"Gemini Code Assist\";\n readonly targetRelativeDir = \".gemini/skills\";\n\n async installSkill(\n targetPath: string,\n skill: SkillMetadata,\n _skillSourceDir: string\n ): Promise<string[]> {\n const file = writeAgentSkillReference(targetPath, this.targetRelativeDir, skill);\n return [file];\n }\n}\n","import { cpSync, existsSync, mkdirSync, rmSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { resolveSkillsSourceRoot } from \"@/domains/installer/resolve-skills-source\";\nimport { getProjectSkillsDir } from \"@/domains/project-store/project-paths\";\nimport { SKILL_CATALOG } from \"@/domains/registry/skill-catalog\";\nimport type { AgentId } from \"@/types/agent.types\";\n\nexport function syncProjectStore(\n targetPath: string,\n selectedSkillIds: string[],\n _selectedAgents: AgentId[]\n): void {\n const bundledSkillsDir = resolveSkillsSourceRoot();\n const projectSkillsDir = getProjectSkillsDir(targetPath);\n\n if (!existsSync(projectSkillsDir)) {\n mkdirSync(projectSkillsDir, { recursive: true });\n }\n\n // Clean legacy cursor-rules directory if it exists\n const legacyCursorRules = join(targetPath, \".grooveskills\", \"cursor-rules\");\n if (existsSync(legacyCursorRules)) {\n try {\n rmSync(legacyCursorRules, { recursive: true, force: true });\n } catch {\n // Ignore cleanup error\n }\n }\n\n for (const skillId of selectedSkillIds) {\n const skill = SKILL_CATALOG.find((item) => item.id === skillId);\n if (!skill) {\n continue;\n }\n\n const sourceSkillDir = join(bundledSkillsDir, skill.directoryName);\n const destSkillDir = join(projectSkillsDir, skill.directoryName);\n\n if (existsSync(sourceSkillDir)) {\n cpSync(sourceSkillDir, destSkillDir, { recursive: true });\n }\n }\n}\n","import { fileURLToPath } from \"node:url\";\nimport { dirname, resolve, join } from \"node:path\";\nimport { existsSync } from \"node:fs\";\n\nexport function resolveSkillsSourceRoot(): string {\n const currentFilePath = fileURLToPath(import.meta.url);\n const currentDir = dirname(currentFilePath);\n\n // 1. From dist/ in published npm package or local build: dist/../skills\n const candidateFromDist = resolve(currentDir, \"../skills\");\n if (existsSync(candidateFromDist)) {\n return candidateFromDist;\n }\n\n // 2. From src/domains/installer/ during development: ../../../skills\n const candidateFromSrc = resolve(currentDir, \"../../../skills\");\n if (existsSync(candidateFromSrc)) {\n return candidateFromSrc;\n }\n\n // 3. Search upward for the package root containing a skills directory\n let searchDir = currentDir;\n for (let i = 0; i < 5; i++) {\n const candidate = join(searchDir, \"skills\");\n if (existsSync(candidate)) {\n return candidate;\n }\n const parent = dirname(searchDir);\n if (parent === searchDir) {\n break;\n }\n searchDir = parent;\n }\n\n throw new Error(\n `GrooveSkills internal error: Unable to locate bundled skills directory from ${currentDir}`\n );\n}\n","import { existsSync, mkdirSync, writeFileSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport {\n getProjectMemoryDir,\n getProjectTasksDir,\n} from \"@/domains/project-store/project-paths\";\nimport {\n buildContextTemplate,\n buildDecisionsTemplate,\n buildOnboardingTaskTemplate,\n buildTaskTemplate,\n} from \"@/domains/harness/harness-templates\";\nimport { scanProjectOnboarding } from \"@/domains/harness/scan-project-onboarding\";\nimport { upsertAgentInstructions } from \"@/domains/harness/upsert-agent-instructions\";\nimport type { HarnessInstallOptions } from \"@/types/harness.types\";\n\nexport function installHarness(options: HarnessInstallOptions): string[] {\n const memoryDir = getProjectMemoryDir(options.targetPath);\n const tasksDir = getProjectTasksDir(options.targetPath);\n const language = options.language ?? \"es\";\n const forceOnboarding = Boolean(options.forceOnboarding);\n\n if (!existsSync(tasksDir)) {\n mkdirSync(tasksDir, { recursive: true });\n }\n\n const createdFiles: string[] = [];\n const contextPath = join(memoryDir, \"context.md\");\n const shouldWriteContext = !existsSync(contextPath) || forceOnboarding;\n\n if (shouldWriteContext) {\n const profile = scanProjectOnboarding(options.targetPath);\n const contextContent = buildContextTemplate(\n options.detectedDependencies,\n language,\n profile\n );\n writeFileSync(contextPath, contextContent, \"utf-8\");\n createdFiles.push(contextPath);\n\n const onboardingTaskPath = join(tasksDir, \"00-onboarding.md\");\n writeFileSync(\n onboardingTaskPath,\n buildOnboardingTaskTemplate(profile.projectName),\n \"utf-8\"\n );\n createdFiles.push(onboardingTaskPath);\n }\n\n const decisionsPath = join(memoryDir, \"decisions.md\");\n if (!existsSync(decisionsPath)) {\n writeFileSync(decisionsPath, buildDecisionsTemplate(language), \"utf-8\");\n createdFiles.push(decisionsPath);\n }\n\n const templateTaskPath = join(tasksDir, \"_template.md\");\n if (!existsSync(templateTaskPath)) {\n writeFileSync(templateTaskPath, buildTaskTemplate(), \"utf-8\");\n createdFiles.push(templateTaskPath);\n }\n\n const instructions = upsertAgentInstructions(\n options.targetPath,\n options.selectedAgents,\n language\n );\n createdFiles.push(...instructions);\n\n return createdFiles;\n}\n","import type { ProjectLanguage } from \"@/types/harness.types\";\n\nexport interface LanguageDefinition {\n code: ProjectLanguage;\n name: string;\n nativeName: string;\n instruction: string;\n}\n\nexport const SUPPORTED_LANGUAGES: Record<ProjectLanguage, LanguageDefinition> = {\n es: {\n code: \"es\",\n name: \"Spanish\",\n nativeName: \"Español\",\n instruction: \"Todos los mensajes, validaciones, errores, CTAs y comunicaciones con el usuario deben redactarse estrictamente en Español. El tono debe ser empático, amable, persuasivo y profesional.\",\n },\n en: {\n code: \"en\",\n name: \"English\",\n nativeName: \"English\",\n instruction: \"All user-facing messages, form validations, errors, CTAs, and notifications must be written strictly in English. Tone must be empathetic, friendly, persuasive, and professional.\",\n },\n pt: {\n code: \"pt\",\n name: \"Portuguese\",\n nativeName: \"Português\",\n instruction: \"Todas as mensagens, validações, erros, CTAs e comunicações voltadas para o usuário devem ser redigidas estritamente em Português. O tom deve ser empático, amigável, persuasivo e profissional.\",\n },\n it: {\n code: \"it\",\n name: \"Italian\",\n nativeName: \"Italiano\",\n instruction: \"Tutti i messaggi, le convalide, gli errori, i pulsanti/CTA e le comunicazioni rivolte all'utente devono essere scritti rigorosamente in Italiano. Il tono deve essere empatico, cordiale, persuasivo e professionale.\",\n },\n fr: {\n code: \"fr\",\n name: \"French\",\n nativeName: \"Français\",\n instruction: \"Tous les messages, validations, erreurs, boutons d'appel à l'action (CTA) et notifications destinés à l'utilisateur doivent être rédigés strictement en Français. Le ton doit être empathique, courtois, persuasif et professionnel.\",\n },\n};\n","import type { ProjectLanguage } from \"@/types/harness.types\";\nimport { SUPPORTED_LANGUAGES } from \"@/domains/harness/harness-languages\";\nimport type { ProjectOnboardingProfile } from \"@/domains/harness/scan-project-onboarding\";\n\nexport function buildContextTemplate(\n detectedDependencies: string[],\n language: ProjectLanguage = \"es\",\n profile?: ProjectOnboardingProfile\n): string {\n const depsFormatted = detectedDependencies.length > 0\n ? detectedDependencies.map((d) => `- \\`${d}\\``).join(\"\\n\")\n : \"- (No external dependencies detected)\";\n\n const langConfig = SUPPORTED_LANGUAGES[language];\n const projectName = profile?.projectName ?? \"Project\";\n const pkgManager = profile?.packageManager ?? \"npm\";\n\n const commandLines: string[] = [];\n if (profile?.commands) {\n for (const [key, cmd] of Object.entries(profile.commands)) {\n commandLines.push(`- **${key}**: \\`${cmd}\\``);\n }\n }\n const commandsSection = commandLines.length > 0\n ? commandLines.join(\"\\n\")\n : `- Build: Refer to \\`package.json\\` scripts.\\n- Typecheck: Refer to TypeScript configuration.\\n- Tests: Refer to test runner configuration.`;\n\n const aliasLines: string[] = [];\n if (profile?.pathAliases) {\n for (const [alias, target] of Object.entries(profile.pathAliases)) {\n aliasLines.push(`- \\`${alias}\\` -> \\`${target}\\``);\n }\n }\n const aliasesSection = aliasLines.length > 0\n ? `\\n### Path Aliases\\n${aliasLines.join(\"\\n\")}\\n`\n : \"\";\n\n const dirLines: string[] = [];\n if (profile?.sourceDirectories && profile.sourceDirectories.length > 0) {\n for (const dir of profile.sourceDirectories) {\n dirLines.push(`- \\`${dir}/\\``);\n }\n }\n const dirsSection = dirLines.length > 0\n ? `\\n### Source Modules\\n${dirLines.join(\"\\n\")}\\n`\n : \"\";\n\n return `# Project Context & Architecture: ${projectName}\n\nThis file provides AI agents with instant architectural orientation for this project.\n\n## 1. Stack & Dependencies\n- **Package Manager**: \\`${pkgManager}\\`\n${depsFormatted}\n\n## 2. Directory Structure Conventions\n- Follow single-responsibility per file (<200 lines).\n- Maintain direct imports with path aliases; avoid barrel files.\n- Keep domain boundaries explicit and clean.\n${aliasesSection}${dirsSection}\n## 3. Communication & User Copy Language\n- **Configured Language**: ${langConfig.nativeName} (\\`${language}\\`).\n- **Policy**: ${langConfig.instruction}\n\n## 4. Essential Commands\n${commandsSection}\n`;\n}\n\nexport function buildDecisionsTemplate(language: ProjectLanguage = \"es\"): string {\n const now = new Date().toISOString().split(\"T\")[0];\n const langConfig = SUPPORTED_LANGUAGES[language];\n\n return `# Architecture Decision Records (ADR)\n\nAn append-only log of significant technical and architectural choices.\n\n| Date | Title | Decision | Reason & Consequences |\n| :--- | :--- | :--- | :--- |\n| ${now} | Adopt GrooveSkills Harness | Initialized \\`.grooveskills/\\` control plane with ODD | Clean, encapsulated agent memory, 3-lane ODD flow, and ${langConfig.nativeName} copy standard |\n`;\n}\n\nexport function buildOnboardingTaskTemplate(projectName: string = \"Project\"): string {\n const now = new Date().toISOString().split(\"T\")[0];\n\n return `---\nstatus: pending\ncreatedAt: ${now}\n---\n\n# 00 — Initial Project Onboarding & Architecture Exploration: ${projectName}\n\n## Outcome Hypothesis\nBy scanning dependencies, entry points, configuration manifests, and module layout, the AI agent will gain a verified architectural understanding of \\`${projectName}\\`, proven by filling out \\`.grooveskills/memory/context.md\\` and validating the essential build/typecheck commands.\n\n## Scope\n- In scope: Inspect project manifests, entry points, directory conventions, and script execution.\n- Out of scope: Refactoring business logic or modifying functional code.\n\n## Checklist\n- [ ] Verify package manager and essential scripts (\\`build\\`, \\`test\\`, \\`typecheck\\`).\n- [ ] Map high-level module architecture and data flow in \\`.grooveskills/memory/context.md\\`.\n- [ ] Verify test runner or static checks pass cleanly.\n- [ ] Switch status to \\`completed\\` once project context is fully verified.\n\n## Evidence\n- Observed command runs and outputs during the initial onboarding pass.\n\n## Next\n- Once onboarding is marked completed, proceed with domain tasks following the 3-lane ODD protocol.\n`;\n}\n\nexport function buildTaskTemplate(): string {\n return `---\nstatus: in-progress\ncreatedAt: \\${CURRENT_DATE}\n---\n\n# Feature / Task Title\n\n## Outcome Hypothesis\nDescribe the expected behavioral outcome:\nBy [Output / Technical Change], [Outcome / Verifiable Behavior] will occur, proven by [Evidence / Test / Build Command].\n\n## Scope\n- In scope:\n- Out of scope:\n\n## Checklist\n- [ ] Task 1: (Define expected observed proof)\n- [ ] Task 2: (Define expected observed proof)\n\n## Evidence\n- Observed test/typecheck/build commands or runtime outputs proving completion.\n\n## Next\n- Next concrete step if interrupted.\n`;\n}\n\nexport function buildAgentHarnessBlock(language: ProjectLanguage = \"es\"): string {\n const langConfig = SUPPORTED_LANGUAGES[language];\n\n return `<!-- grooveskills:harness:start -->\n# GrooveSkills Harness — Agent Rules & Memory\n\nThis project uses the **GrooveSkills Harness** located in \\`.grooveskills/\\`.\n\n## 1. Three-Lane ODD Protocol\n- **Onboarding Check**: If \\`.grooveskills/memory/tasks/00-onboarding.md\\` has \\`status: pending\\`, complete its checklist to enrich \\`context.md\\` and set its status to \\`completed\\`.\n- **Authorize & Explore**: Follow the 7-step ODD protocol (Authorize, Explore, Resolve, Classify, Track & Hypothesize, Execute, Verify).\n- **Lane 1 (Answer)**: Explanations, audits, or questions. Read-only; write zero code.\n- **Lane 2 (Task)**: Direct implementation. Declare Outcome Hypothesis and checklist in \\`.grooveskills/memory/tasks/<slug>.md\\`. Only check off tasks with observed evidence under \\`Evidence\\`.\n- **Lane 3 (Spec)**: Ambiguous or high-impact architecture. Clarify and validate the spec in \\`.grooveskills/memory/tasks/<slug>.md\\` before writing code.\n\n## 2. User Communication Language (${langConfig.nativeName})\n- **Language**: \\`${language}\\` (${langConfig.nativeName}).\n- **Requirement**: ${langConfig.instruction}\n\n## 3. Memory Locations\n- Architecture context: \\`.grooveskills/memory/context.md\\`\n- Technical decisions (ADR): \\`.grooveskills/memory/decisions.md\\`\n- Active tasks & evidence: \\`.grooveskills/memory/tasks/\\`\n<!-- grooveskills:harness:end -->`;\n}\n","import { existsSync, readdirSync, readFileSync } from \"node:fs\";\nimport { basename, join } from \"node:path\";\n\nexport interface ProjectOnboardingProfile {\n projectName: string;\n packageManager: string;\n commands: Record<string, string>;\n pathAliases: Record<string, string>;\n sourceDirectories: string[];\n}\n\nfunction detectProjectName(targetPath: string): string {\n const packageJsonPath = join(targetPath, \"package.json\");\n if (existsSync(packageJsonPath)) {\n try {\n const raw = readFileSync(packageJsonPath, \"utf-8\");\n const parsed = JSON.parse(raw) as { name?: string };\n if (typeof parsed.name === \"string\" && parsed.name.trim().length > 0) {\n return parsed.name.trim();\n }\n } catch {\n // Fall through to other manifests\n }\n }\n\n const cargoPath = join(targetPath, \"Cargo.toml\");\n if (existsSync(cargoPath)) {\n try {\n const cargoRaw = readFileSync(cargoPath, \"utf-8\");\n const nameMatch = cargoRaw.match(/name\\s*=\\s*\"([^\"]+)\"/);\n if (nameMatch?.[1]) {\n return nameMatch[1];\n }\n } catch {\n // Fall through\n }\n }\n\n const pyprojectPath = join(targetPath, \"pyproject.toml\");\n if (existsSync(pyprojectPath)) {\n try {\n const pyRaw = readFileSync(pyprojectPath, \"utf-8\");\n const pyMatch = pyRaw.match(/name\\s*=\\s*\"([^\"]+)\"/);\n if (pyMatch?.[1]) {\n return pyMatch[1];\n }\n } catch {\n // Fall through\n }\n }\n\n return basename(targetPath) || \"project\";\n}\n\nfunction detectPackageManager(targetPath: string): string {\n if (existsSync(join(targetPath, \"pnpm-lock.yaml\"))) {\n return \"pnpm\";\n }\n if (existsSync(join(targetPath, \"bun.lockb\")) || existsSync(join(targetPath, \"bun.lock\"))) {\n return \"bun\";\n }\n if (existsSync(join(targetPath, \"yarn.lock\"))) {\n return \"yarn\";\n }\n if (existsSync(join(targetPath, \"package-lock.json\"))) {\n return \"npm\";\n }\n if (existsSync(join(targetPath, \"Cargo.lock\")) || existsSync(join(targetPath, \"Cargo.toml\"))) {\n return \"cargo\";\n }\n if (existsSync(join(targetPath, \"uv.lock\"))) {\n return \"uv\";\n }\n if (existsSync(join(targetPath, \"poetry.lock\"))) {\n return \"poetry\";\n }\n return \"npm\";\n}\n\nfunction detectCommands(targetPath: string, pkgManager: string): Record<string, string> {\n const packageJsonPath = join(targetPath, \"package.json\");\n if (!existsSync(packageJsonPath)) {\n return {};\n }\n\n try {\n const raw = readFileSync(packageJsonPath, \"utf-8\");\n const parsed = JSON.parse(raw) as { scripts?: Record<string, string> };\n const scripts = parsed.scripts ?? {};\n const commands: Record<string, string> = {};\n\n const runner = pkgManager === \"npm\" ? \"npm run\" : pkgManager;\n\n if (scripts.build) {\n commands.build = `${runner} build`;\n }\n if (scripts[\"check-types\"]) {\n commands.typecheck = `${runner} check-types`;\n } else if (scripts.typecheck) {\n commands.typecheck = `${runner} typecheck`;\n } else if (scripts.tsc) {\n commands.typecheck = `${runner} tsc`;\n }\n\n if (scripts.test) {\n commands.test = `${runner} test`;\n }\n if (scripts.lint) {\n commands.lint = `${runner} lint`;\n }\n if (scripts.dev) {\n commands.dev = `${runner} dev`;\n }\n\n return commands;\n } catch {\n return {};\n }\n}\n\nfunction detectPathAliases(targetPath: string): Record<string, string> {\n const tsconfigPath = join(targetPath, \"tsconfig.json\");\n if (!existsSync(tsconfigPath)) {\n return {};\n }\n\n try {\n const raw = readFileSync(tsconfigPath, \"utf-8\");\n const parsed = JSON.parse(raw) as {\n compilerOptions?: {\n paths?: Record<string, string[]>;\n };\n };\n const paths = parsed.compilerOptions?.paths ?? {};\n const aliases: Record<string, string> = {};\n\n for (const [key, targets] of Object.entries(paths)) {\n if (Array.isArray(targets) && typeof targets[0] === \"string\") {\n aliases[key] = targets[0];\n }\n }\n\n return aliases;\n } catch {\n return {};\n }\n}\n\nfunction detectSourceDirectories(targetPath: string): string[] {\n const srcPath = join(targetPath, \"src\");\n const scanTarget = existsSync(srcPath) ? srcPath : targetPath;\n\n try {\n const entries = readdirSync(scanTarget, { withFileTypes: true });\n return entries\n .filter((entry) => entry.isDirectory())\n .map((entry) => entry.name)\n .filter((name) => !name.startsWith(\".\") && name !== \"node_modules\" && name !== \"dist\");\n } catch {\n return [];\n }\n}\n\nexport function scanProjectOnboarding(targetPath: string): ProjectOnboardingProfile {\n const projectName = detectProjectName(targetPath);\n const packageManager = detectPackageManager(targetPath);\n const commands = detectCommands(targetPath, packageManager);\n const pathAliases = detectPathAliases(targetPath);\n const sourceDirectories = detectSourceDirectories(targetPath);\n\n return {\n projectName,\n packageManager,\n commands,\n pathAliases,\n sourceDirectories,\n };\n}\n","import { existsSync, readFileSync, writeFileSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { buildAgentHarnessBlock } from \"@/domains/harness/harness-templates\";\nimport type { AgentId } from \"@/types/agent.types\";\nimport type { ProjectLanguage } from \"@/types/harness.types\";\n\nconst START_MARKER = \"<!-- grooveskills:harness:start -->\";\nconst END_MARKER = \"<!-- grooveskills:harness:end -->\";\n\nfunction applyHarnessBlock(filePath: string, language: ProjectLanguage = \"es\"): void {\n const block = buildAgentHarnessBlock(language);\n\n if (!existsSync(filePath)) {\n writeFileSync(filePath, `${block}\\n`, \"utf-8\");\n return;\n }\n\n const existingContent = readFileSync(filePath, \"utf-8\");\n\n if (existingContent.includes(START_MARKER) && existingContent.includes(END_MARKER)) {\n const regex = new RegExp(`${START_MARKER}[\\\\s\\\\S]*?${END_MARKER}`, \"g\");\n const updated = existingContent.replace(regex, block);\n writeFileSync(filePath, updated, \"utf-8\");\n return;\n }\n\n const separator = existingContent.endsWith(\"\\n\") ? \"\\n\" : \"\\n\\n\";\n writeFileSync(filePath, `${existingContent}${separator}${block}\\n`, \"utf-8\");\n}\n\nexport function upsertAgentInstructions(\n targetPath: string,\n selectedAgents: AgentId[],\n language: ProjectLanguage = \"es\"\n): string[] {\n const updatedFiles: string[] = [];\n\n const agentsMdPath = join(targetPath, \"AGENTS.md\");\n applyHarnessBlock(agentsMdPath, language);\n updatedFiles.push(agentsMdPath);\n\n if (selectedAgents.includes(\"claude\")) {\n const claudeMdPath = join(targetPath, \"CLAUDE.md\");\n applyHarnessBlock(claudeMdPath, language);\n updatedFiles.push(claudeMdPath);\n }\n\n return updatedFiles;\n}\n","import { existsSync, readFileSync, writeFileSync } from \"node:fs\";\nimport { getProjectConfigPath } from \"@/domains/project-store/project-paths\";\nimport type { GrooveSkillsConfig, ProjectLanguage } from \"@/types/harness.types\";\nimport type { AgentId } from \"@/types/agent.types\";\n\ninterface ParsedConfigState {\n skills: string[];\n agents: AgentId[];\n harness: boolean;\n language?: ProjectLanguage;\n}\n\nfunction readExistingConfig(configPath: string): ParsedConfigState {\n const fallback: ParsedConfigState = {\n skills: [],\n agents: [],\n harness: false,\n };\n\n if (!existsSync(configPath)) {\n return fallback;\n }\n\n try {\n const raw = readFileSync(configPath, \"utf-8\");\n const parsed = JSON.parse(raw) as Partial<GrooveSkillsConfig>;\n\n return {\n skills: Array.isArray(parsed.skills) ? parsed.skills : [],\n agents: Array.isArray(parsed.agents) ? parsed.agents : [],\n harness: typeof parsed.harness === \"boolean\" ? parsed.harness : false,\n language: typeof parsed.language === \"string\" ? (parsed.language as ProjectLanguage) : undefined,\n };\n } catch {\n return fallback;\n }\n}\n\nexport function writeProjectConfig(\n targetPath: string,\n newSkills: string[],\n newAgents: AgentId[],\n harnessEnabled: boolean,\n language?: ProjectLanguage\n): string {\n const configPath = getProjectConfigPath(targetPath);\n const existing = readExistingConfig(configPath);\n\n const mergedSkills = Array.from(new Set([...existing.skills, ...newSkills]));\n const mergedAgents = Array.from(new Set([...existing.agents, ...newAgents]));\n const resolvedLanguage = language ?? existing.language ?? \"es\";\n const isHarnessActive = existing.harness || harnessEnabled;\n\n const config: GrooveSkillsConfig = {\n version: 1,\n harness: isHarnessActive,\n ...(isHarnessActive ? { language: resolvedLanguage } : {}),\n agents: mergedAgents,\n skills: mergedSkills,\n updatedAt: new Date().toISOString(),\n };\n\n writeFileSync(configPath, `${JSON.stringify(config, null, 2)}\\n`, \"utf-8\");\n\n return configPath;\n}\n","import { detectProjectContext } from \"@/domains/detector/project-detector\";\nimport { runInteractiveUi } from \"@/domains/ui/ui-orchestrator\";\nimport { installSkills } from \"@/domains/installer/install-orchestrator\";\nimport type { AgentId } from \"@/types/agent.types\";\nimport type { ProjectLanguage } from \"@/types/harness.types\";\n\nexport interface CliOptions {\n skills?: string[];\n agents?: AgentId[];\n yes?: boolean;\n harness?: boolean;\n language?: ProjectLanguage;\n forceOnboarding?: boolean;\n}\n\nexport async function runGrooveSkills(options: CliOptions = {}): Promise<void> {\n const targetPath = process.cwd();\n const context = detectProjectContext(targetPath);\n\n const hasSkills = options.skills && options.skills.length > 0;\n const hasAgents = options.agents && options.agents.length > 0;\n const isDirectHarness = Boolean(options.harness) && hasAgents;\n const isDirectInit = Boolean(options.forceOnboarding) && hasAgents;\n\n if ((hasSkills && hasAgents) || isDirectHarness || isDirectInit) {\n const language = options.language ?? context.configuredLanguage ?? \"es\";\n await installSkills({\n targetPath,\n selectedSkillIds: options.skills || [],\n selectedAgents: options.agents || [],\n forceOverwrite: Boolean(options.yes),\n enableHarness: true,\n detectedDependencies: context.detectedDependencies,\n language,\n forceOnboarding: options.forceOnboarding,\n });\n return;\n }\n\n await runInteractiveUi(context, Boolean(options.forceOnboarding));\n}\n"],"mappings":";AAAA,SAAS,cAAAA,aAAY,gBAAAC,qBAAoB;AACzC,SAAS,QAAAC,aAAY;;;ACDrB,SAAS,mBAAmB;AAGrB,SAAS,aAAa,YAA+B;AAC1D,QAAM,WAAsB,CAAC;AAE7B,MAAI;AACF,UAAM,UAAU,IAAI,IAAI,YAAY,UAAU,CAAC;AAE/C,QAAI,QAAQ,IAAI,SAAS,GAAG;AAC1B,eAAS,KAAK,aAAa;AAAA,IAC7B;AACA,QAAI,QAAQ,IAAI,SAAS,GAAG;AAC1B,eAAS,KAAK,QAAQ;AA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MAAK,aAAa,aAAc,mBAAmB,cAAc;AAC/D,UAAM,WAAW,QAAQ,YAAY,QAAQ,sBAAsB;AACnE,UAAM,cAAc;AAAA,MAClB;AAAA,MACA,kBAAkB,QAAQ,UAAU,CAAC;AAAA,MACrC,gBAAgB,QAAQ,UAAU,CAAC;AAAA,MACnC,gBAAgB,QAAQ,QAAQ,GAAG;AAAA,MACnC,eAAe;AAAA,MACf,sBAAsB,QAAQ;AAAA,MAC9B;AAAA,MACA,iBAAiB,QAAQ;AAAA,IAC3B,CAAC;AACD;AAAA,EACF;AAEA,QAAM,iBAAiB,SAAS,QAAQ,QAAQ,eAAe,CAAC;AAClE;","names":["existsSync","readFileSync","join","join","existsSync","readFileSync","p","pc","p","p","p","join","join","existsSync","lstatSync","readFileSync","join","join","existsSync","lstatSync","readFileSync","join","existsSync","mkdirSync","rmSync","join","join","existsSync","existsSync","mkdirSync","join","rmSync","existsSync","mkdirSync","writeFileSync","join","existsSync","readdirSync","readFileSync","join","existsSync","readFileSync","writeFileSync","join","existsSync","writeFileSync","readFileSync","join","existsSync","mkdirSync","join","writeFileSync","existsSync","readFileSync","writeFileSync","existsSync","readFileSync","writeFileSync","join","confirm","pc","s"]}
|