docs-init skill
✓ 인증됨코드베이스를 탐색하고 검증된 정보로 템플릿을 채워 문서화 구조를 초기화합니다.
- GitHub 스타
- 8
- 파일
- 3
- 마지막 커밋
- 2026년 10월 28일
- 라이선스
- MIT
- 허용된 도구
- —
docs-init skill은 무엇을 하나요?
코드베이스를 탐색하고 검증된 정보로 템플릿을 채워 문서화 구조를 초기화합니다.
skill의 SKILL.md에서 생성된 요약입니다.
docs-init skill 정보
docs-init은 문서화가 되어 있지 않은 코드베이스를 위해 포괄적인 문서 폴더를 설정할 수 있게 해줍니다. 이 도구는 새로운 프로젝트를 시작하거나 docs/ 디렉토리가 없는 기존 저장소를 관리하는 개발자를 위해 설계되었습니다. 패키지 매니페스트, 데이터베이스 모델, 인프라 설정 등을 검색하여 코드베이스를 탐색하고 프로젝트의 구체적인 특성을 파악합니다.
기술 스택이 파악되면 assets/templates/에 있는 템플릿을 사용하여 architecture.md, onboarding.md, data-model.md와 같은 파일을 생성합니다. 엄격한 환각 방지 규칙을 준수하여 모든 내용은 추측이 아닌 실제 코드 분석 결과에 기반합니다. 또한 mmdc 도구를 사용하여 Mermaid 다이어그램을 검증함으로써 다이어그램이 올바르게 렌더링되는지 확인합니다. 이 프로세스는 기존 문서를 업데이트하기보다는 초기 스캐폴딩을 목적으로 합니다.
agent가 수행할 수 있는 작업
- 1새 프로젝트 문서 스캐폴딩완전히 새로운 저장소를 위해 처음부터 전체 문서 구조를 초기화합니다.
- 2배포 및 보안 문서 자동화Dockerfile과 같은 인프라 파일이 있는 경우 배포 및 보안 문서를 생성합니다.
- 3다이어그램 구문 검증새 문서에 포함된 Mermaid 다이어그램의 구문이 올바른지 확인합니다.
skill의 SKILL.md를 기반으로 작성되었습니다. 모든 사용 사례는 해당 문서의 인용구와 대조 확인되었습니다.
docs-init skill 설치 방법
각 명령은 skill 폴더를 클라이언트의 skills 디렉터리에 복사합니다. 클라이언트를 재시작하거나 새 세션을 시작하여 로드하세요.플러그인에 docs-init skill 설치
/plugin marketplace add mgiovani/cc-arsenal /plugin install cc-arsenal@cc-arsenal-marketplace
Claude Code에 docs-init skill 설치
~/.claude/skills/docs-init/SKILL.md
$ npx degit mgiovani/cc-arsenal/skills/docs-init ~/.claude/skills/docs-initClaude Code (project)에 docs-init skill 설치
.claude/skills/docs-init/SKILL.md
$ npx degit mgiovani/cc-arsenal/skills/docs-init .claude/skills/docs-initCodex에 docs-init skill 설치
~/.agents/skills/docs-init/SKILL.md
$ npx degit mgiovani/cc-arsenal/skills/docs-init ~/.agents/skills/docs-initGemini CLI에 docs-init skill 설치
~/.gemini/skills/docs-init/SKILL.md
$ npx degit mgiovani/cc-arsenal/skills/docs-init ~/.gemini/skills/docs-initClaude.ai에 docs-init skill 설치
npx degit mgiovani/cc-arsenal/skills/docs-init docs-init && zip -r docs-init.zip docs-init # claude.ai → Customize → Skills → + → Create skill → Upload a skill → docs-init.zip
자동 검사
2026년 11월 15일에 실행됨전체 보고서 →자동 검사를 통과했습니다. 보안 감사는 아닙니다. 에이전트가 실행하기 전에 스크립트를 읽어 보세요. 검사 방식 · 점수를 높이기 위해 수정할 항목
- 소스 저장소 연결 및 접근 가능mgiovani/cc-arsenal/skills/docs-init is public and reachablegithub.com/mgiovani/cc-arsenal/tree/HEAD/skills/docs-init ↗통과
- 오픈 소스 라이선스 (OSI)MITspdx.org/licenses/MIT.html ↗통과
- 최근 1년 내 커밋 또는 릴리스Last commit 2026-10-28github.com/mgiovani/cc-arsenal/commits ↗통과
- 스크립트에 다운로드 후 실행이나 자격 증명 탈취가 없음No scripts in the skill folder통과
- SKILL.md에 숨겨진 지침 없음No override phrases, safeguard switches, credential requests or hidden charactersgithub.com/mgiovani/cc-arsenal/blob/HEAD/skills/docs-init/SK ↗통과
- 사전 허용 도구가 제한됨No pre-approved tools; the agent asks before using onegithub.com/mgiovani/cc-arsenal/blob/HEAD/skills/docs-init/SK ↗통과
- SKILL.md가 Agent Skills 형식을 따름the description does not say when to use the skillgithub.com/mgiovani/cc-arsenal/blob/HEAD/skills/docs-init/SK ↗결함 발견
SKILL.md
GitHub에서 보기Initialize Project Documentation
Bootstrap a docs/ structure for a project with little or no existing documentation. Only generate what the codebase actually evidences.
Anti-hallucination guidelines
Every claim in generated docs must trace to something read or grepped in this run:
- Verify a file/directory exists before referencing it.
- Get counts from
ls/find/grep, never estimate. - Quote real function/class/table names, not assumed ones.
- An empty directory is not a feature, don't document it.
- If a claim can't be verified, drop it rather than guess.
Workflow
1. Explore the codebase
Find: source directories with actual code, package manager files (package.json, pyproject.toml, go.mod, Cargo.toml, ...), database/ORM files, infrastructure configs (Docker, k8s, Terraform), and any existing docs/. See Detection Commands below for the exact patterns.
If a Task/subagent tool is available, delegate this to an Explore agent with that scope. Otherwise run the same grep/find commands inline and Read each hit: the result must be the same either way.
Verify every finding before using it: read the package manifest, read the model file, confirm a directory has real files inside it, not just an empty folder.
2. Detect project characteristics
From the exploration, determine: language/framework stack, project type (web app, CLI, library, service), whether a database/ORM is present, and whether infrastructure/deployment configs exist. These characteristics drive which doc types Phase 3 decides to generate.
3. Decide which docs to generate
- Always:
docs/architecture.md,docs/onboarding.md,docs/adr/0001-record-architecture-decisions.md(Nygard-format meta-ADR, generate inline, no template file) - If a database/ORM was found:
docs/data-model.md - If deployment configs were found (Dockerfile, k8s manifest, CI workflow, IaC):
docs/deployment.md,docs/security.md - If the project looks collaborative (multiple contributors in
git log, an open-source license, no existing CONTRIBUTING):docs/contributing.md,docs/rfc/directory
Don't generate a doc type with no supporting evidence: an empty data-model.md for a stateless CLI is worse than no file at all.
4. Check for existing docs
Scan docs/. For any target file that already exists, do not overwrite it: list it under "skipped" and ask the user before touching it. This skill is safe to rerun: by default it only fills gaps.
5. Populate templates
Templates live in assets/templates/ (see reference table below). For each one you're using:
- Grep it for its actual placeholder set:
grep -oE '\{\{[A-Z_0-9]+\}\}' assets/templates/<name>.md | sort -u - Map every placeholder to a value from step 1/2's verified findings. Never leave a placeholder as a literal
{{TOKEN}}in the output. - Templates mark some sections as conditional with an HTML comment ("delete if...", "only if evidenced"). Where the codebase gives no evidence for that section, delete the whole section (heading included, not just the placeholder text).
- After writing the file, grep it for
\{\{[A-Z_0-9]+\}\}again. Zero matches. If any remain, resolve or delete them before moving on.
Worked example (a FastAPI + PostgreSQL service):
$ grep -oE '\{\{[A-Z_0-9]+\}\}' assets/templates/architecture.md | sort -u
{{COMPONENT_DEPENDENCIES}}
{{COMPONENT_DESCRIPTION}}
{{COMPONENT_NAME}}
{{DATA_FLOW}}
{{DATE}}
{{DEPLOYMENT_SUMMARY}}
...
Map each to a verified finding: {{TECHNOLOGY_STACK}} becomes "Python 3.12, FastAPI 0.115, PostgreSQL 16 via SQLAlchemy", read from pyproject.toml and the model files, not assumed. If security.md's Compliance section has no GDPR/HIPAA evidence in the codebase (no consent flow, no PHI handling), delete that whole section rather than fill it with a guess.
6. Write the files
Create docs/ (and docs/adr/, docs/rfc/ if needed). Write each file that isn't being skipped.
7. Validate the diagrams render
Skip if none of the files you wrote has a ```mermaid block. Otherwise you need mmdc: install with npm i -g @mermaid-js/mermaid-cli, or run it ad hoc by defining mmdc() { npx -y -p @mermaid-js/mermaid-cli mmdc "$@"; } first. If Chromium refuses to launch in a sandbox, add -p with a puppeteer config of {"args":["--no-sandbox"]}.
Run this on the files you wrote; each FAIL <name>-N.mmd names the doc and the Nth mermaid block in it:
d=$(mktemp -d)
for md in <the docs/ files you wrote>; do
awk -v out="$d/${md//\//__}" '/^```mermaid/{f=out "-" ++n ".mmd"; next} /^```/{f=""} f{print > f}' "$md"
done
for f in "$d"/*.mmd; do mmdc -q -i "$f" -o "${f%.mmd}.svg" || echo "FAIL $f"; done
Fix each failing block using its parser error, then re-run until nothing prints FAIL. Cap at 3 rounds, then report the blocks that still fail. If mmdc can't be installed (no Node, offline), say so in the report and fall back to a careful syntax review of each diagram.
8. Report
List what was created, what was skipped (already existed), diagram validation result (rendered, or still failing, or unvalidated), and next steps.
Template Reference
| Document | Template | Generated when |
|---|---|---|
| Architecture | architecture.md |
always |
| Onboarding | onboarding.md |
always |
| First ADR | inline (Nygard format) | always |
| Data Model | data-model.md |
database/ORM detected |
| Deployment | deployment.md |
deployment config detected |
| Security | security.md |
deployment config detected |
| Contributing | contributing.md |
collaborative project |
Detection Commands
Run these directly (or hand them to the Explore agent from step 1):
# Language/framework
find . -name "package.json" -o -name "pyproject.toml" -o -name "go.mod" -o -name "Cargo.toml" | head -5
# Database/ORM
find . -name "*models.py" -o -name "*schema.prisma" -o -name "*entity.ts" | head -5
# Infrastructure
find . -name "Dockerfile" -o -name "docker-compose.yml" -o -name "*.k8s.yaml" | head -5
# Project name and description
basename "$(git rev-parse --show-toplevel 2>/dev/null || pwd)"
head -20 README.md 2>/dev/null
Usage Examples
docs-init
docs-init for Python FastAPI microservice
docs-init for Next.js SaaS application
Example Output
Documentation Initialization Complete
Created:
docs/architecture.md - System architecture overview
docs/onboarding.md - Developer onboarding guide
docs/adr/0001-record-architecture-decisions.md - Meta-ADR
docs/data-model.md - Database schema (SQLAlchemy detected)
docs/deployment.md - Deployment guide (Docker detected)
Skipped (already exists):
docs/contributing.md
Next steps:
1. Review and customize the generated docs
2. docs-diagram er / docs-diagram arch for standalone diagrams
3. docs-adr "Decision Title" for future ADRs
Notes
- Safe to rerun: only fills gaps, asks before overwriting existing files.
- User-supplied context (e.g. "for a FastAPI microservice") steers detection but doesn't replace verification: still confirm the stack from the actual files.
이 스킬의 파일
3docs-init skill 질문
Claude Code에 docs-init skill을 어떻게 설치하나요?
npx degit mgiovani/cc-arsenal/skills/docs-init ~/.claude/skills/docs-init를 실행합니다. Claude Code는 ~/.claude/skills(모든 프로젝트) 또는 .claude/skills(한 프로젝트)에서 skills를 로드하며, 설명이 작업과 일치할 때 skill을 사용합니다.
docs-init skill을 사용할 수 있는 클라이언트는 무엇인가요?
Agent Skills 형식을 읽는 모든 클라이언트(Claude Code, Codex, Gemini CLI, claude.ai(ZIP으로 업로드))가 사용할 수 있습니다. skill 내 스크립트는 클라이언트가 코드 실행을 허용하는 경우에만 실행됩니다.
이미 문서 파일이 존재하는 경우에는 어떻게 되나요?
docs/ 디렉토리를 스캔하여 이미 존재하는 대상 파일은 건너뜁니다. 건너뛴 파일은 'skipped' 목록에 표시되며, 파일을 수정하기 전에 사용자에게 확인을 요청합니다.
도구가 프로젝트에 대해 잘못된 정보를 생성(hallucination)할 가능성이 있나요?
아니요, 이 SKILL은 엄격한 환각 방지 가이드라인을 따릅니다. 모든 내용은 코드베이스에서 읽거나 grep으로 검색한 내용에 근거해야 하며, 근거를 찾을 수 없는 섹션은 삭제합니다.
기존 문서를 업데이트하는 용도로 사용할 수 있나요?
아니요, 이 SKILL은 새로운 docs/ 폴더를 초기화하거나 스캐폴딩하는 용도로 설계되었습니다. 기존 문서를 최신 상태로 유지하거나 동기화하려면 docs-update를 사용해야 합니다.