.claude/skills/feature/SKILL.md
End-to-end feature development. Creates git branch, plans implementation via /ai-factory.task, then executes via /ai-factory.implement — full cycle without manual steps. Use when user says "new feature", "start feature", "implement feature", or "add feature".
npx skillsauth add YaroslavKomarov/ShedulerBot ai-factory.featureInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Start a new feature by creating a branch and planning implementation.
FIRST: Read .ai-factory/DESCRIPTION.md if it exists to understand:
This context informs branch naming, task planning, and implementation.
Check if git is initialized. If not, initialize it.
git rev-parse --is-inside-work-tree 2>/dev/null || git init
Extract flags from $ARGUMENTS before parsing the feature description:
--parallel → Enable parallel worktree mode
--list → Show all active worktrees with feature status
--cleanup <branch> → Remove worktree and optionally delete branch
Parsing rules:
--parallel, --list, --cleanup <branch> from $ARGUMENTS--list and --cleanup are standalone — they execute immediately and stop (do NOT continue to Step 1+)Examples:
/ai-factory.feature --parallel Add user authentication
→ parallel=true, description="Add user authentication"
/ai-factory.feature --list
→ show all active worktrees, then STOP
/ai-factory.feature --cleanup feature/user-auth
→ remove worktree for that branch, then STOP
/ai-factory.feature Add user authentication
→ normal flow (unchanged), parallel=false
If --list is present, jump to the --list Subcommand section.
If --cleanup is present, jump to the --cleanup Subcommand section.
Otherwise, continue to Step 1.
From $ARGUMENTS, extract:
Create a descriptive branch name:
Format: <type>/<short-description>
Examples:
- feature/user-authentication
- feature/stripe-checkout
- feature/product-search
- fix/cart-total-calculation
- refactor/api-error-handling
Rules:
IMPORTANT: Always ask the user before proceeding:
Before we start, a few questions:
1. Should I write tests for this feature?
- [ ] Yes, write tests
- [ ] No, skip tests
2. Update documentation after implementation?
- [ ] Yes, update docs (/ai-factory.docs)
- [ ] No, skip docs
3. Any specific requirements or constraints?
Store the testing and documentation preferences - they will be passed to /ai-factory.task and /ai-factory.implement.
Only when --parallel flag is set. If not set, skip to Step 4 (Normal).
This creates an isolated working directory so multiple features can be developed concurrently, each with its own Claude Code session.
DIRNAME=$(basename "$(pwd)")
# e.g. "my-project"
git branch <branch-name> main
If the branch already exists, ask the user whether to reuse it or pick a different name.
git worktree add ../${DIRNAME}-<branch-name-with-hyphens> <branch-name>
Convert the branch name for the directory: replace / with -.
Example:
Project dir: my-project
Branch: feature/user-auth
Worktree: ../my-project-feature-user-auth
Copy these files/directories so the worktree has full AI context:
WORKTREE="../${DIRNAME}-<branch-name-with-hyphens>"
# Project context
cp .ai-factory/DESCRIPTION.md "${WORKTREE}/.ai-factory/DESCRIPTION.md" 2>/dev/null
# Past lessons / patches
cp -r .ai-factory/patches/ "${WORKTREE}/.ai-factory/patches/" 2>/dev/null
# Claude Code skills + settings (required for Claude Code to work)
cp -r .claude/ "${WORKTREE}/.claude/" 2>/dev/null
# CLAUDE.md only if it exists and is NOT tracked by git
if [ -f CLAUDE.md ] && ! git ls-files --error-unmatch CLAUDE.md &>/dev/null; then
cp CLAUDE.md "${WORKTREE}/CLAUDE.md"
fi
Note: Files tracked by git are already in the worktree via the checkout. Only copy untracked context files.
mkdir -p "${WORKTREE}/.ai-factory/features"
cd "${WORKTREE}"
Display a brief confirmation:
✅ Parallel worktree created!
Branch: <branch-name>
Directory: <worktree-path>
To manage worktrees later:
/ai-factory.feature --list
/ai-factory.feature --cleanup <branch-name>
Continue to Step 5 — invoke /ai-factory.task in the worktree directory to start planning immediately.
# Ensure we're on main/master and up to date
git checkout main
git pull origin main
# Create and switch to new branch
git checkout -b <branch-name>
If branch already exists, ask user:
Plan file will be named after the branch:
Branch: feature/user-authentication
Plan file: .ai-factory/features/feature-user-authentication.md (NOT .ai-factory/PLAN.md!)
Convert branch name to filename:
/ with -.md extensionCall /ai-factory.task with explicit context:
/ai-factory.task $ARGUMENTS
CONTEXT FROM /ai-factory.feature:
- Plan file: .ai-factory/features/feature-user-authentication.md (use this name, NOT .ai-factory/PLAN.md)
- Testing: yes/no
- Logging: verbose/standard/minimal
IMPORTANT: Pass the exact plan filename to /ai-factory.task. This distinguishes feature-based work from direct /ai-factory.task calls.
Pass along:
.ai-factory/features/feature-user-authentication.md)The plan file allows resuming work based on current git branch:
git branch --show-current # → feature/user-authentication
# → Look for .ai-factory/features/feature-user-authentication.md
Parallel mode (--parallel): Automatically invoke /ai-factory.implement — the whole point of parallel is autonomous end-to-end execution in an isolated worktree.
/ai-factory.implement
CONTEXT FROM /ai-factory.feature:
- Plan file: .ai-factory/features/<branch-name>.md
- Testing: yes/no
- Logging: verbose/standard/minimal
- Docs: yes/no
Normal mode: STOP after planning. The user reviews the plan and decides when to implement.
Plan created! To start implementation:
/ai-factory.implement
Context is heavy after branch creation and planning. All results are saved to the plan file — suggest freeing space:
AskUserQuestion: Free up context before continuing?
Options:
1. /clear — Full reset (recommended)
2. /compact — Compress history
3. Continue as is
When --list is passed, show all active worktrees and their feature status. Then STOP — do not continue the normal workflow.
# Show all worktrees
git worktree list
Additionally, for each worktree path from the output:
<worktree>/.ai-factory/features/ contains any plan filesOutput format:
Active worktrees:
/path/to/my-project (main) ← you are here
/path/to/my-project-feature-user-auth (feature/user-auth) → Plan: feature-user-auth.md
/path/to/my-project-fix-cart-bug (fix/cart-bug) → No plan yet
When --cleanup <branch> is passed, remove the worktree and optionally delete the branch. Then STOP.
DIRNAME=$(basename "$(pwd)")
BRANCH_DIR=$(echo "<branch>" | tr '/' '-')
WORKTREE="../${DIRNAME}-${BRANCH_DIR}"
# Remove the worktree
git worktree remove "${WORKTREE}"
# Only delete branch if it's been merged into main
git branch -d <branch> # -d (not -D) will fail if unmerged, which is safe
If git branch -d fails because the branch is unmerged, inform the user:
⚠️ Branch <branch> has unmerged changes.
To force-delete: git branch -D <branch>
To merge first: git checkout main && git merge <branch>
If the worktree path doesn't exist, check git worktree list and suggest the correct path.
User: /ai-factory.feature Add user authentication with email/password and OAuth
Actions:
feature/user-authenticationgit checkout -b feature/user-authentication/ai-factory.task → creates plan, user reviews/ai-factory.implement when readyUser: /ai-factory.feature --parallel Add Stripe checkout integration
Actions:
--parallel found, description = "Add Stripe checkout integration"feature/stripe-checkoutmy-projectgit branch feature/stripe-checkout maingit worktree add ../my-project-feature-stripe-checkout feature/stripe-checkoutcd into worktree/ai-factory.task → creates plan, user reviews/ai-factory.implement → executes the plan (parallel = autonomous)User: /ai-factory.feature --list
Actions:
git worktree list.ai-factory/features/User: /ai-factory.feature --cleanup feature/stripe-checkout
Actions:
../my-project-feature-stripe-checkoutgit worktree remove ../my-project-feature-stripe-checkoutgit branch -d feature/stripe-checkoutUser: /ai-factory.feature Fix cart not updating quantities correctly
Actions:
fix/cart-quantity-update/ai-factory.task → creates plan, user reviews/ai-factory.implement when readyWhen asking about testing, also ask about logging:
Before we start:
1. Should I write tests for this feature?
- [ ] Yes, write tests
- [ ] No, skip tests
2. Logging level for implementation:
- [ ] Verbose (recommended) - detailed DEBUG logs for development
- [ ] Standard - INFO level, key events only
- [ ] Minimal - only WARN/ERROR
3. Update documentation after implementation?
- [ ] Yes, update docs (/ai-factory.docs)
- [ ] No, skip docs
4. Any specific requirements or constraints?
Default to verbose logging. AI-generated code benefits greatly from extensive logging because:
Logging must always be configurable:
Pass the logging and documentation preferences to /ai-factory.task along with testing preference.
development
Verify completed implementation against the plan. Checks that all tasks were fully implemented, nothing was forgotten, code compiles, tests pass, and quality standards are met. Use after "/ai-factory.implement" completes, or when user says "verify", "check work", "did we miss anything".
data-ai
Create a step-by-step implementation plan for a feature or task. Breaks down work into actionable tasks tracked via the task system. Use when user says "plan", "create tasks", "break down", or "make a plan for".
tools
# Supabase TypeScript Patterns Patterns for using Supabase with TypeScript in this project. Uses **service role key** (server-side only). Tables are prefixed `sch_`. ## Client Setup ```typescript // src/db/client.ts import { createClient } from "@supabase/supabase-js"; import type { Database } from "./types"; // generated types export const supabase = createClient<Database>( process.env.SUPABASE_URL!, process.env.SUPABASE_SERVICE_ROLE_KEY!, // server-side only, bypasses RLS { auth:
development
Generate professional Agent Skills for Claude Code and other AI agents. Creates complete skill packages with SKILL.md, references, scripts, and templates. Use when creating new skills, generating custom slash commands, or building reusable AI capabilities. Validates against Agent Skills specification.