aiwg-update-agents-md
Update AGENTS.md with project-specific context for Factory AI based on codebase analysis
от jmagly★ 233 звезды на GitHub
Установить aiwg-update-agents-md в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Skill access pattern (post-kernel-pivot, 2026.5+)
Skill names referenced in this document are AIWG skills, not slash commands. Most are not kernel-listed and cannot be invoked as
/skill-nameby the platform. Reach them via:aiwg discover "<capability>" aiwg show skill <name> --bodyOnly kernel-listed skills (
aiwg-doctor,aiwg-refresh,aiwg-status,aiwg-help,use,aiwg-steward-routingon Claude Code) are directly invokable as slash commands. See skill-discovery rule.
AIWG Update AGENTS.md
You are a Technical Documentation Specialist responsible for updating AGENTS.md files with project-specific context and AIWG framework integration for Factory AI.
Your Task
When invoked with /aiwg-update-agents-md [project-directory] [--provider factory] (Factory AI) or /aiwg-update-agents-md [project-directory] (Claude Code):
- Analyze the project codebase structure
- Detect build/test commands from package.json, Makefile, or scripts
- Identify architecture patterns and conventions
- Read existing AGENTS.md (if present) to preserve user content
- Update AGENTS.md with project-specific commands and AIWG context
- Validate the updated AGENTS.md is complete
Important Context
This command is specifically designed for Factory AI users. It creates or updates AGENTS.md to include:
- Project-specific build/test/run commands (analyzed from codebase)
- AIWG SDLC Framework integration section
- Factory droid usage examples
- Multi-agent workflow patterns
For Claude Code users, use aiwg-update-claude instead (note the / prefix for Claude Code).
Execution Steps
Step 1: Analyze Codebase
Detect Project Type and Commands:
PROJECT_DIR="${1:-.}"
cd "$PROJECT_DIR"
# Check for package.json (Node.js/TypeScript)
if [ -f "package.json" ]; then
PROJECT_TYPE="node"
# Extract common scripts
SCRIPTS=$(node -pe "JSON.parse(fs.readFileSync('package.json')).scripts" 2>/dev/null || echo "{}")
fi
# Check for Makefile
if [ -f "Makefile" ]; then
PROJECT_TYPE="${PROJECT_TYPE}-make"
fi
# Check for Python (requirements.txt, pyproject.toml, setup.py)
if [ -f "requirements.txt" ] || [ -f "pyproject.toml" ] || [ -f "setup.py" ]; then
PROJECT_TYPE="${PROJECT_TYPE}-python"
fi
# Check for Go (go.mod)
if [ -f "go.mod" ]; then
PROJECT_TYPE="go"
fi
# Check for Rust (Cargo.toml)
if [ -f "Cargo.toml" ]; then
PROJECT_TYPE="rust"
fi
Use Bash tool to detect project type.
Extract Build Commands:
For Node.js projects, read package.json and extract critical scripts:
test- Test commandbuild- Build commandlint- Linting commanddevorstart- Development servercoverageortest:coverage- Coverage command
Use Read tool to read package.json, then parse scripts.
Example extraction:
{
"scripts": {
"test": "jest",
"build": "tsc",
"lint": "eslint src/",
"dev": "tsx watch src/index.ts",
"test:coverage": "jest --coverage"
}
}
Step 2: Detect Architecture Patterns
Scan project structure to identify:
- Source directory (
src/,lib/,app/) - Test directory (
tests/,test/,__tests__/) - Configuration files (
.env,config/) - Documentation (
docs/,README.md)
Use Glob tool to scan directories.
Identify patterns:
- Monorepo (Nx, Turborepo, Lerna)
- Microservices (multiple services/)
- Monolith (single src/)
- Frontend/Backend split
- Full-stack (client/ + server/)
Use Grep tool to search for framework-specific patterns:
- React: Search for
import Reactorfrom 'react' - Vue: Search for
<template>orvue - Express: Search for
express()orfrom 'express' - FastAPI: Search for
FastAPIorfrom fastapi - Django: Search for
djangoimports
Step 3: Read Existing AGENTS.md (If Present)
Check if AGENTS.md already exists:
AGENTS_MD="$PROJECT_DIR/AGENTS.md"
if [ -f "$AGENTS_MD" ]; then
echo "Found existing AGENTS.md"
EXISTING_CONTENT=$(cat "$AGENTS_MD")
# Check if it already has AIWG section
if echo "$EXISTING_CONTENT" | grep -q "AIWG SDLC Framework"; then
echo "⚠️ AGENTS.md already contains AIWG section"
HAS_AIWG=true
else
echo "No AIWG section found, will append"
HAS_AIWG=false
fi
else
echo "No existing AGENTS.md, will create from scratch"
EXISTING_CONTENT=""
HAS_AIWG=false
fi
Use Read tool to read existing AGENTS.md, Grep to detect AIWG section.
Step 4: Generate Project-Specific Commands Section
IMPORTANT: Keep project-specific content concise (≤75 lines) to maintain total AGENTS.md ≤150 lines (75/75 split).
Based on codebase analysis, generate the project commands section:
For Node.js/TypeScript projects:
## Project Commands
```bash
npm test # Run tests
npm run build # Build project
npm run lint
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл aiwg-update-agents-md?
Update AGENTS.md with project-specific context for Factory AI based on codebase analysis
Как установить скилл aiwg-update-agents-md?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл aiwg-update-agents-md запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
skill-creator
AnthropicCreate new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
discernment-nudge
AnthropicAfter you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
data-consolidate
AnthropicJoins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
inspection-to-capa
AnthropicRuns the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…