diff --git a/.ai-agents/AGENTS.md b/.claude/AGENTS.md similarity index 100% rename from .ai-agents/AGENTS.md rename to .claude/AGENTS.md diff --git a/.claude/commands/ai-specialist.md b/.claude/commands/ai-specialist.md new file mode 100644 index 0000000..6cac03a --- /dev/null +++ b/.claude/commands/ai-specialist.md @@ -0,0 +1 @@ +Read `.claude/roles/ai-specialist.md` and adopt the @ai-specialist role for this task: $ARGUMENTS diff --git a/.claude/commands/bug-fix.md b/.claude/commands/bug-fix.md new file mode 100644 index 0000000..0f366a1 --- /dev/null +++ b/.claude/commands/bug-fix.md @@ -0,0 +1 @@ +Read `.claude/workflows/bug-fix.md` and start the bug fix workflow for: $ARGUMENTS diff --git a/.claude/commands/domain.md b/.claude/commands/domain.md new file mode 100644 index 0000000..3222c13 --- /dev/null +++ b/.claude/commands/domain.md @@ -0,0 +1,12 @@ +Read `.claude/domains/$ARGUMENTS/context.md` and use it as your working context. + +After reading, summarize: +1. Key business rules +2. Main entities +3. Available commands and queries +4. API endpoints +5. Related domains + +Then confirm you are ready to work on the **$ARGUMENTS** domain. + +Available domains: `feed`, `article`, `bookmark`, `newsletter`, `search`, `spotlight` diff --git a/.claude/commands/engineer.md b/.claude/commands/engineer.md new file mode 100644 index 0000000..ee0a23b --- /dev/null +++ b/.claude/commands/engineer.md @@ -0,0 +1 @@ +Read `.claude/roles/engineer.md` and adopt the @engineer role for this task: $ARGUMENTS diff --git a/.claude/commands/frontend.md b/.claude/commands/frontend.md new file mode 100644 index 0000000..32d7186 --- /dev/null +++ b/.claude/commands/frontend.md @@ -0,0 +1 @@ +Read `.claude/roles/frontend.md` and adopt the @frontend role for this task: $ARGUMENTS diff --git a/.claude/commands/hotfix.md b/.claude/commands/hotfix.md new file mode 100644 index 0000000..81a063b --- /dev/null +++ b/.claude/commands/hotfix.md @@ -0,0 +1,39 @@ +Start an expedited hotfix workflow for the production issue: $ARGUMENTS + +This is a HOTFIX — keep changes minimal and focused on the fix only. + +## Steps + +1. **Create hotfix branch from master** + ```bash + git checkout master && git pull + git checkout -b hotfix/$ARGUMENTS + ``` + +2. **Diagnose quickly** + - Check logs: `docker compose logs app | grep -i error` + - Identify the exact file and line causing the issue + - Root cause in one sentence + +3. **Minimal fix only** + - Change the least amount of code necessary + - No refactoring, no unrelated improvements + - If the root cause requires a larger fix, implement a safe temporary workaround and create a follow-up task + +4. **Regression test** + - Write one test that reproduces the bug and passes after the fix + - Run `make tests-unit` + +5. **Commit** + ``` + fix(domain): [HOTFIX] brief description + + Root cause: [one line] + Regression test added. + ``` + +6. **PR and deploy** + - `gh pr create` targeting `master` + - After merge, monitor logs for 10 minutes + +Read `.claude/workflows/bug-fix.md` for the full workflow if the issue requires deeper investigation. diff --git a/.claude/commands/infra.md b/.claude/commands/infra.md new file mode 100644 index 0000000..dd9ede8 --- /dev/null +++ b/.claude/commands/infra.md @@ -0,0 +1 @@ +Read `.claude/roles/infra.md` and adopt the @infra role for this task: $ARGUMENTS diff --git a/.claude/commands/new-feature.md b/.claude/commands/new-feature.md new file mode 100644 index 0000000..248a076 --- /dev/null +++ b/.claude/commands/new-feature.md @@ -0,0 +1 @@ +Read `.claude/workflows/new-feature.md` and start the new feature workflow for: $ARGUMENTS diff --git a/.claude/commands/quality.md b/.claude/commands/quality.md new file mode 100644 index 0000000..010d150 --- /dev/null +++ b/.claude/commands/quality.md @@ -0,0 +1,14 @@ +Run the full quality check suite and report results. + +Execute in order: +1. `make lint` — PHP CS Fixer +2. `make analyse` — PHPStan level 9 +3. `make rector` — Rector refactoring check +4. `make tests-unit` — PHPUnit unit tests + +For each step that fails, explain: +- What failed and why +- The exact fix needed +- Whether it can be auto-fixed (e.g. `make lint` can auto-fix CS issues) + +Context (optional): $ARGUMENTS diff --git a/.claude/commands/release.md b/.claude/commands/release.md new file mode 100644 index 0000000..602af2c --- /dev/null +++ b/.claude/commands/release.md @@ -0,0 +1 @@ +Read `.claude/workflows/release.md` and start the release workflow for version: $ARGUMENTS diff --git a/.claude/commands/review.md b/.claude/commands/review.md new file mode 100644 index 0000000..9582ff0 --- /dev/null +++ b/.claude/commands/review.md @@ -0,0 +1,3 @@ +Read `.claude/roles/reviewer.md` and perform a code review. Context: $ARGUMENTS + +If no context is given, review the current git diff: run `git diff HEAD` and `git diff --staged` to get the changes to review. diff --git a/.ai-agents/domains/article/context.md b/.claude/domains/article/context.md similarity index 100% rename from .ai-agents/domains/article/context.md rename to .claude/domains/article/context.md diff --git a/.ai-agents/domains/bookmark/context.md b/.claude/domains/bookmark/context.md similarity index 100% rename from .ai-agents/domains/bookmark/context.md rename to .claude/domains/bookmark/context.md diff --git a/.ai-agents/domains/feed/context.md b/.claude/domains/feed/context.md similarity index 100% rename from .ai-agents/domains/feed/context.md rename to .claude/domains/feed/context.md diff --git a/.ai-agents/domains/newsletter/context.md b/.claude/domains/newsletter/context.md similarity index 100% rename from .ai-agents/domains/newsletter/context.md rename to .claude/domains/newsletter/context.md diff --git a/.ai-agents/domains/search/context.md b/.claude/domains/search/context.md similarity index 100% rename from .ai-agents/domains/search/context.md rename to .claude/domains/search/context.md diff --git a/.ai-agents/domains/spotlight/context.md b/.claude/domains/spotlight/context.md similarity index 100% rename from .ai-agents/domains/spotlight/context.md rename to .claude/domains/spotlight/context.md diff --git a/.ai-agents/roles/ai-specialist.md b/.claude/roles/ai-specialist.md similarity index 97% rename from .ai-agents/roles/ai-specialist.md rename to .claude/roles/ai-specialist.md index e419ef4..3ed89c2 100644 --- a/.ai-agents/roles/ai-specialist.md +++ b/.claude/roles/ai-specialist.md @@ -8,9 +8,9 @@ ## Prerequisites Before starting any task: -1. Read `shared/architecture.md` for async patterns -2. Read `domains/search/context.md` for vector search specifics -3. Read `domains/newsletter/context.md` for LLM synthesis +1. Read `.claude/shared/architecture.md` for async patterns +2. Read `.claude/domains/search/context.md` for vector search specifics +3. Read `.claude/domains/newsletter/context.md` for LLM synthesis 4. Check existing AI code in `src/Infrastructure/AI/` --- diff --git a/.ai-agents/roles/engineer.md b/.claude/roles/engineer.md similarity index 97% rename from .ai-agents/roles/engineer.md rename to .claude/roles/engineer.md index 1ac0e34..d067ee3 100644 --- a/.ai-agents/roles/engineer.md +++ b/.claude/roles/engineer.md @@ -8,9 +8,9 @@ ## Prerequisites Before starting any task: -1. Read `shared/architecture.md` for CQRS and API Platform patterns -2. Read `shared/conventions.md` for naming rules -3. Read relevant `domains/{domain}/context.md` +1. Read `.claude/shared/architecture.md` for CQRS and API Platform patterns +2. Read `.claude/shared/conventions.md` for naming rules +3. Read relevant `.claude/domains/{domain}/context.md` 4. Check existing code in `src/Domain/{Domain}/` for style matching --- diff --git a/.ai-agents/roles/frontend.md b/.claude/roles/frontend.md similarity index 98% rename from .ai-agents/roles/frontend.md rename to .claude/roles/frontend.md index 1182c71..8128901 100644 --- a/.ai-agents/roles/frontend.md +++ b/.claude/roles/frontend.md @@ -8,8 +8,8 @@ ## Prerequisites Before starting any task: -1. Read `shared/conventions.md` for naming rules -2. Read `shared/boundaries.md` for what you can/cannot do +1. Read `.claude/shared/conventions.md` for naming rules +2. Read `.claude/shared/boundaries.md` for what you can/cannot do 3. Check existing components in `frontend/src/components/` 4. Verify API contracts with @engineer if needed diff --git a/.ai-agents/roles/infra.md b/.claude/roles/infra.md similarity index 99% rename from .ai-agents/roles/infra.md rename to .claude/roles/infra.md index ce3d2b3..9c2a0d5 100644 --- a/.ai-agents/roles/infra.md +++ b/.claude/roles/infra.md @@ -8,7 +8,7 @@ ## Prerequisites Before starting any task: -1. Read `shared/boundaries.md` for approval requirements +1. Read `.claude/shared/boundaries.md` for approval requirements 2. Check current Docker Compose configuration 3. Review existing migrations in `migrations/` 4. Understand current CI/CD pipeline diff --git a/.ai-agents/roles/marketer.md b/.claude/roles/marketer.md similarity index 99% rename from .ai-agents/roles/marketer.md rename to .claude/roles/marketer.md index 91220f3..6bd259e 100644 --- a/.ai-agents/roles/marketer.md +++ b/.claude/roles/marketer.md @@ -8,7 +8,7 @@ ## Prerequisites Before creating content: -1. Read `shared/boundaries.md` for what you cannot do +1. Read `.claude/shared/boundaries.md` for what you cannot do 2. **Read `/docs/MARKETING-STRATEGY.md`** for pricing, communication roadmap, and templates 3. Consult `@engineer` to verify technical claims 4. Check current product roadmap diff --git a/.ai-agents/roles/reviewer.md b/.claude/roles/reviewer.md similarity index 97% rename from .ai-agents/roles/reviewer.md rename to .claude/roles/reviewer.md index 8f66c09..f8490f4 100644 --- a/.ai-agents/roles/reviewer.md +++ b/.claude/roles/reviewer.md @@ -8,9 +8,9 @@ ## Prerequisites Before reviewing: -1. Read `shared/architecture.md` for expected patterns -2. Read `shared/conventions.md` for naming/style rules -3. Read `shared/boundaries.md` for role restrictions +1. Read `.claude/shared/architecture.md` for expected patterns +2. Read `.claude/shared/conventions.md` for naming/style rules +3. Read `.claude/shared/boundaries.md` for role restrictions 4. Understand the feature context from domain files --- diff --git a/.ai-agents/shared/architecture.md b/.claude/shared/architecture.md similarity index 100% rename from .ai-agents/shared/architecture.md rename to .claude/shared/architecture.md diff --git a/.ai-agents/shared/boundaries.md b/.claude/shared/boundaries.md similarity index 100% rename from .ai-agents/shared/boundaries.md rename to .claude/shared/boundaries.md diff --git a/.ai-agents/shared/conventions.md b/.claude/shared/conventions.md similarity index 100% rename from .ai-agents/shared/conventions.md rename to .claude/shared/conventions.md diff --git a/.ai-agents/workflows/bug-fix.md b/.claude/workflows/bug-fix.md similarity index 100% rename from .ai-agents/workflows/bug-fix.md rename to .claude/workflows/bug-fix.md diff --git a/.ai-agents/workflows/new-feature.md b/.claude/workflows/new-feature.md similarity index 99% rename from .ai-agents/workflows/new-feature.md rename to .claude/workflows/new-feature.md index 6d27d83..4078429 100644 --- a/.ai-agents/workflows/new-feature.md +++ b/.claude/workflows/new-feature.md @@ -54,7 +54,7 @@ Use this template to ask the user: ### Read Domain Context ``` -.ai-agents/domains/{relevant-domain}/context.md +.claude/domains/{relevant-domain}/context.md ``` ### Check Existing Code diff --git a/.ai-agents/workflows/release.md b/.claude/workflows/release.md similarity index 100% rename from .ai-agents/workflows/release.md rename to .claude/workflows/release.md diff --git a/CLAUDE.md b/CLAUDE.md index 70344eb..d399928 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -584,15 +584,18 @@ Message → Handler → External API/AI → Repository update # 12. Agents -This project uses specialized agents defined in `.ai-agents/`: +This project uses specialized agents defined in `.claude/`: | Agent | File | Purpose | |-------|------|---------| -| `@signalist-engineer` | `engineering.md` | Backend development, CQRS, Symfony | -| `@signalist-frontend` | `frontend.md` | React, TypeScript, MUI components | -| `@signalist-ai` | `ai-integration.md` | Symfony AI, MCP, embeddings | -| `@signalist-infra` | `infrastructure.md` | Docker, PostgreSQL, Redis | -| `@signalist-marketer` | `marketing.md` | Content, growth, positioning | +| `@engineer` | `.claude/roles/engineer.md` | Backend development, CQRS, Symfony | +| `@frontend` | `.claude/roles/frontend.md` | React, TypeScript, MUI components | +| `@ai-specialist` | `.claude/roles/ai-specialist.md` | Symfony AI, MCP, embeddings | +| `@infra` | `.claude/roles/infra.md` | Docker, PostgreSQL, Redis | +| `@reviewer` | `.claude/roles/reviewer.md` | Code quality, security, architecture | +| `@marketer` | `.claude/roles/marketer.md` | Content, growth, positioning | + +See `.claude/AGENTS.md` for routing, coordination protocol, and domain contexts. ## 12.1 Marketing Resources