Logo Project Init

Project Init

Cộng đồng
AlexZio00
project-init

Interview-based project setup — generates CLAUDE.md, ROADMAP, .gitignore, .env.example from scratch. Use when: user says '/project-init', 'new project', 'project creation', 'project setup', 'create project'. NOT for AI agent/harness configuration (use setup for that). Conversational, one question at a time.

Tổng quan

Nhà phát hànhAlexZio00
Kho mãsovereign-skills
Tên kỹ năngproject-init
Sao
149
Bản fork
23
Tệp đi kèm
2
Giấy phépMIT
Liên kết
  • Hướng dẫn bằng Markdown

    Tệp SKILL.md được mô hình tải khi cần, nên chỉ tốn token khi có yêu cầu thực sự phù hợp.

  • Dùng được với mọi LLM

    Kỹ năng AI dùng hướng dẫn viết bằng Markdown thay vì mã dành riêng cho một nhà cung cấp, nên dùng được với GPT, Claude, Gemini, Grok hoặc mô hình cục bộ.

  • 2 tệp đi kèm

    Các tập lệnh, mẫu và tài liệu tham khảo mà mô hình có thể đọc khi làm việc. Các tệp chỉ cho phép đọc và không bao giờ được thực thi.

  • Mã nguồn mở

    Được AlexZio00 công bố trên GitHub. Hãy đọc các tệp nguồn trước khi cài đặt.

Cài đặt

Cài đặt kỹ năng AI Project Init trong TypingMind để dùng với bất kỳ LLM nào, hoặc thêm vào một tác nhân AI khác có thể đọc SKILL.md.

1

Cài đặt trong TypingMind

TypingMind cài đặt kỹ năng trực tiếp từ thư mục GitHub — đọc SKILL.md, đóng gói các tệp tài nguyên và lưu kết quả trên máy.

  1. Mở ứng dụng và vào Plugin → Kỹ năng.
  2. Chọn "Cài đặt từ GitHub".
  3. Dán URL của thư mục kỹ năng được hiển thị bên dưới rồi xác nhận.
    https://github.com/AlexZio00/sovereign-skills/tree/master/project-init
  4. Bật kỹ năng trong từng cuộc trò chuyện mà bạn muốn sử dụng kỹ năng đó.
Plugin → Kỹ năng → Thêm kỹ năng → Từ URL GitHub, sau đó dán URL thư mục và nhấn Tiếp tục.
2

Cài đặt trong tác nhân AI khác

Bất kỳ tác nhân AI nào đọc được định dạng Agent Skills đều có thể dùng kỹ năng này — hãy sao chép thư mục vào thư mục kỹ năng của tác nhân AI đó.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/AlexZio00/sovereign-skills.git /tmp/sovereign-skills
mkdir -p .claude/skills
cp -r /tmp/sovereign-skills/project-init .claude/skills/project-init
Khởi động lại Claude Code sau khi sao chép để ứng dụng nhận kỹ năng mới.

Sử dụng trong TypingMind

Bật Project Init trong bất kỳ cuộc trò chuyện nào trên TypingMind, mô hình sẽ tự xử lý phần còn lại. Tên và mô tả của kỹ năng nằm trong prompt hệ thống. Ngay khi có yêu cầu phù hợp, mô hình tự tải toàn bộ hướng dẫn — bạn không cần gọi thủ công và kỹ năng không tốn token cho đến khi thực sự được dùng.

Mô hình tự nạp Project Init ngay khi có yêu cầu phù hợp.

Dùng được với mọi mô hình AI

Kỹ năng AI là các hướng dẫn Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên bạn có thể dùng Project Init với cả những mô hình khác ngoài mô hình ban đầu. Chỉ cần cài đặt một lần trong TypingMind rồi dùng với GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama hoặc mô hình cục bộ do bạn tự chạy — tất cả đều dùng khóa API của riêng bạn.

  • Chỉ tải khi cần

    Prompt hệ thống chỉ chứa tên và mô tả. Hướng dẫn được tải khi có yêu cầu phù hợp đầu tiên, nên khi kỹ năng chưa được dùng, bạn không tốn token cho phần hướng dẫn.

  • Đổi mô hình ngay trong cuộc trò chuyện

    Vì kỹ năng là hướng dẫn chứ không phải mã, việc đổi mô hình không làm kỹ năng ngừng hoạt động — mô hình tiếp theo vẫn đọc cùng tệp SKILL.md.

Hướng dẫn của kỹ năng

Đây là nội dung SKILL.md mà mô hình tải. Hãy đọc trước khi cài đặt — kỹ năng là những hướng dẫn mà mô hình của bạn sẽ làm theo.

Project Init — New Project Design Interview

Dominant Variable

Do interview decisions map exactly to generated files? — If interview answers conflict with CLAUDE.md/ROADMAP content, the project starts on a false premise.

Purpose

Capture every critical decision before writing a single line of code.

Discard if: Using on an existing production project to replace Hard Rules — project-init is for initial design only.

Trigger

  • /project-init
  • "new project", "create project", "project setup"

Key Assumptions

  1. Empty or new project directory — if broken: existing file conflicts need resolution.
  2. Write tool accessible — if broken: output file contents as code blocks and user saves manually.

Phase 0: Context Check

0-1. Existing CLAUDE.md Detection

Check if CLAUDE.md exists in the current working directory.

  • Not found → proceed to Phase 1 normally.
  • Found → read it, then ask:
    CLAUDE.md already exists. What would you like to do?
    1. Update — enhance based on existing content (keep Hard Rules, add missing sections)
    2. Rewrite — start fresh from scratch (delete existing content)
    3. Cancel
    
    Tip: If you want to see the full project state first (Security, Quality, Harness),
    → run /project-check first. Then come back here and select Update mode.
    • Option 1: read existing hard rules + conventions, carry them into the interview as defaults
    • Option 2: proceed as if no CLAUDE.md exists
    • Option 3: stop

0-1b. Other Target Files (overwrite protection)

The CLAUDE.md prompt above is not the only overwrite risk. Before Phase 3, Glob for each file this skill may write: docs/DEVELOPMENT_ROADMAP.md, .gitignore, .env.example, docs/decisions/README.md. For every one that already exists, never overwrite it silently; offer:

  1. Merge — append only the missing lines or keys (.gitignore entries, .env.example variables, new ROADMAP phases), keep everything else
  2. Replace — only after you copy the old file to <file>.bak-YYYYMMDD and the user confirms
  3. Skip this file Default: Merge. Report which option was applied per file.

0-2. Brief / Context File

If the user provides a file path or pastes a project brief, read it first. Extract any stack decisions or constraints to pre-fill interview answers.

0-3. Smart Defaults

After Phase 0, check for context clues before asking each Q.

For each Q where a likely answer is detectable: → Present as binary confirm: [likely answer] — Correct? (Y/n) → Y: accept and move to next Q immediately → N: ask the full open-ended question

If no context available → ask all questions open-ended as normal.

Default signals by Q:

  • Q2 (Language): file extensions in directory — .py → Python, .ts/.tsx → TypeScript, go.mod → Go, Cargo.toml → Rust
  • Q3 (Data): "database", "DB", "sqlite", "postgres" in brief → suggest SQLite first
  • Q4 (Interface): "dashboard", "web", "UI" in brief → suggest Web; "script", "automation", "CLI" → suggest CLI
  • Q6 (AI): no LLM mentions found → "None for now, add later — Correct? (Y/n)"
  • Q8 (Scope): default to "1 month+, solo" unless team or deadline mentioned

Phase 1: Interview (one question at a time)

Ask the questions below one at a time. Confirm understanding before moving to the next. Adjust later questions based on earlier answers.

Q1 — Core Definition

Describe the project in one sentence.
[What] [Who uses it] [Why they need it]

Q2 — Language / Runtime

What language are you thinking? (If undecided, say so — let's choose together)

Decision guide:
- Python: data, ML, automation, scripting → unbeatable ecosystem
- TypeScript: web UI, API server → full-stack unification
- Java/Kotlin: Spring Boot backend, Android app → enterprise/mobile
- Go: high-performance server, CLI tools, concurrency → single binary deploy
- Rust: systems-level, embedded, extreme performance
- Swift: native iOS/macOS apps

Q3 — Data Layer

Where does data come from, and where does it live?

- Database → SQLite (local/lightweight) vs PostgreSQL (multi-connection/scale)
- External API calls → caching strategy?
- Files only → what format?
- None (pure computation/transformation)

Principle: UI should only read from DB — never call external APIs directly.
Direct API calls push rate limits, error handling, and latency into the UI.

Q4 — Interface

How do users interact with it?

- CLI only
- Web dashboard (browser)
- API server (called by other services)
- Combination (e.g. CLI + dashboard)
- None (background service / daemon)

Q5 — Deployment

Where does it run?

- Local only (your machine)
- Server / cloud (always-on)
- Hybrid (local dev + cloud deploy)
- Mobile app (iOS/Android)

Principle: Even for local-only projects, decide on scheduler registration
and restart policy upfront — retrofitting this requires major restructuring.

Q6 — AI / LLM

Any AI features?

- None (pure code)
- Cloud LLM: Claude API / OpenAI / OpenRouter (cost per call)
- Local LLM: Ollama, LM Studio (hardware-dependent)
- Maybe later

Principles:
- Always gate LLM features behind a feature flag (default OFF)
- Daily cost cap + budget guard required
- Design cloud fallback before local hardware is available

Q7 — Hard Rules (Invariants)

Are there rules that must never be broken?

Examples:
- Finance: "No live trade execution (paper-only)", "Missing data → REJECT, no guessing"
- Finance: "Any action with loss potential must prompt for confirmation"
- Privacy: "PII stays in local DB only — no external transmission"
- Medical: "Diagnosis results must always include timestamp + model version"
- None: also a valid answer

Principle: Document these before writing code.
Adding them later means existing code may already be in violation.

If Q7 = "None": Do not generate an empty Hard Rules section. Instead, apply domain-appropriate minimum defaults based on Q2+Q6:

  • All projects: "no hardcoded secrets: credentials via environment variables only"
  • If Q6 involves LLM: "no fabrication: when data is missing, say so — never invent"
  • If Q3 involves database: "no raw SQL in user-facing code: parameterized queries or ORM only"
  • If Q4 is web-facing: "input validation on every user-facing endpoint"

Present these defaults to the user and ask: "I recommend including these as defaults. Let me know if you want to remove any."

Hard Rules must always have at least one entry. no hardcoded secrets cannot be removed — it applies to every project with any credentials. If the user insists on removing everything, refuse and explain: CLAUDE.md without any Hard Rules is not permitted by this skill.

Q8 — Scope & Timeline

How long will this take? Solo or team?

- Under 1 week: script-level → keep structure minimal (CLAUDE.md only)
- 1–4 weeks: mini project → CLAUDE.md + ROADMAP + test suite
- 1 month+: full project → complete structure + ROADMAP
- Team: add contribution guide + PR template

Phase 2: Stack Decision Summary

Based on interview answers, present a summary:

Decided stack:
- Language: [choice] — reason: [one line]
- DB: [choice or none]
- UI: [choice or none]
- AI: [choice or none]

Hard Rules:
1. [from Q7]
2. [additional recommendations based on domain/scope]

Open decisions:
- [anything still undecided]

Confirm with user before Phase 3.


Phase 3: File Generation

Templates are separated into references/templates.md. Read that file when generating any of the files below. Read ${CLAUDE_SKILL_DIR}/references/templates.md (${CLAUDE_SKILL_DIR} is this skill's folder; Claude Code fills it in. In other agents, replace it with the path where you installed the skill.)

Files to generate:

  • 3-1. CLAUDE.md — always generated
  • 3-2. docs/DEVELOPMENT_ROADMAP.md — if timeline > 1 week (Q8)
  • 3-3. .gitignore — language-specific (based on Q2)
  • 3-4. .env.example — if API keys/secrets involved (Q3/Q6)
  • 3-5. Folder Structure — suggested as text only (not created on disk)
  • 3-6. docs/decisions/README.md — if Q8 > 1 month or Q7 produced significant Hard Rules

CLAUDE.md size and splitting rules (apply when generating 3-1): Keep CLAUDE.md under 200 lines (official guidance, https://code.claude.com/docs/en/memory — adherence drops as the file grows). Do not create .claude/rules/ files here (that is /setup's scope). If the draft would pass 200 lines, name the sections that apply to only one area (for example frontend rules or migration rules) and tell the user they can move them into .claude/rules/<topic>.md with a paths: frontmatter list of globs (for example - "src/api/**/*.ts") via /setup or by hand. Always keep these in CLAUDE.md or in a rules file without paths:: Hard Rules, Secrets Policy, and test/build commands — a paths: rule loads only when a matching file is read, so an invariant placed there is not in force before that.

The exact template structure for each file, per-language .gitignore/.env.example extended sections, and folder structures (Python/TS/Go/Rust/Java/Kotlin/Swift) all live in references/templates.md.


Phase 4: Refinement Loop

After generating files:

Draft complete. Review and let me know what to change.

Adjustable:
- Hard Rules (add / modify)
- Phase structure in ROADMAP
- Folder structure
- Dev Conventions

Approve → files confirmed
[change request] → apply and regenerate

Regeneration rules — which files to regenerate per change:

ChangeRegenerate
Language switch (Q2).gitignore, .env.example, folder structure, Quick Ref in CLAUDE.md
DB layer change (Q3).env.example (DB section), Hard Rules suggestion
LLM toggle (Q6).env.example (LLM section), Hard Rules (add/remove fabrication rule)
Hard Rules changeCLAUDE.md only; also update ADR-001 in docs/decisions/README.md if that file exists (Q8 > 1 month OR Q7 was flagged significant — same eligibility as 3-6)
Timeline/scope changeROADMAP only; re-evaluate docs/decisions/ eligibility
All changesRe-run Checklist after regeneration

Safety Layers

Risky ActionReversibilityApplied Layers
CLAUDE.md generation (Replace if exists)mediumL1+L3
.env.example generationhighL3
.gitignore generation/overwritemediumL1+L3
docs/decisions/README.md initializationmediumL1+L3
  • L1 (Invariants): When existing files are detected, enforce Phase 0 Overwrite Protection (CLAUDE.md: Update / Rewrite / Cancel; other files: Merge / Replace with backup / Skip).
  • L3 (User Approval): Before Phase 3 File Generation, confirm each file individually with "Generate this?" — no batch approval.
  • Forbidden: Auto-generate .env (actual secrets file). Template only: .env.example. Refuse even if user requests "auto-generate .env".

Error Recovery

When failure detected: Stop → Classify → Apply Recovery → Report & Resume.

Failure TypeDetection ConditionRecovery Path
tool_failureCLAUDE.md / .gitignore Write failsOutput file content as code block → user saves manually
tool_failureA guard or hook blocks writing .env.exampleDo not retry. Print the content as a code block for the user to save.
input_errorProject type/tech stack unclearRe-run Phase 0 interview questions. Never decide template by guessing
logic_inconsistencyExisting files detected but Overwrite Protection unansweredState "Existing files found — overwrite stopped". Never silently overwrite
missing_dataTarget project root directory missingState "Directory not found" → confirm with user before proceeding

Truthful Reporting

After generating files:

  1. no mock deception: Run actual Write, then verify with Bash ls. Confirm file existence before reporting "created".
  2. no test façade: If generation fails, don't bundle as "done". Report each file as success/failure individually.
  3. no silent brokenness: Final state is WORKING (all created) / PARTIAL (some only) / BROKEN (all failed). For PARTIAL, list missing files.

Output

Files generated (all at project root unless noted):

  • CLAUDE.md — always generated
  • docs/DEVELOPMENT_ROADMAP.md — if timeline > 1 week (Q8)
  • .gitignore — based on language choice (Q2)
  • .env.example — if API keys or secrets involved (Q3/Q6)
  • docs/decisions/README.md — if timeline > 1 month (Q8) or Q7 produced significant Hard Rules

Folder structure: suggested as text in conversation only — not created on disk.


Rationalization Table

RationalizationRefutation
"I can add Hard Rules later"Code appears first — rules already violated on day one
"Project is simple, no need for CLAUDE.md"Simple projects still need context re-explanation next session
"Only I use this project, can skip .env.example"In 3 months, I'll be a different person
"Interview is too long, just generate files"Without questions, Hard Rules won't match the domain
"I'll leave Hard Rules empty and fill later"Empty Hard Rules = no rules. Minimum 1 required always
"The existing CLAUDE.md is probably outdated, just overwrite it"Invariant 2 — run the Phase 0 detection and user-choice prompt first. Overwriting silently destroys existing Hard Rules.
"The user needs keys to run, auto-fill .env"Forbidden. Generate .env.example as a template only; never write real secrets.

Invariants (never violate)

  1. Hard Rules always present: Never generate CLAUDE.md without at least one Hard Rule. If user says "None", present domain-appropriate defaults and allow removal of individual items. Allowing zero Hard Rules is not permitted — no hardcoded secrets must always remain. Violation → CLAUDE.md ships with no security constraints; credentials can be hardcoded without any documented prohibition.
  2. Phase 0 mandatory: Never overwrite an existing CLAUDE.md, ROADMAP, .gitignore, .env.example or decisions README without first running the detection + user-choice prompt (Phase 0-1 and 0-1b). User may choose rewrite, but the prompt must happen first. Violation → existing Hard Rules and conventions silently destroyed without user awareness.
  3. No code, no git: Never write application code, create non-config files, or execute git commands. The only non-config files this skill creates are docs/DEVELOPMENT_ROADMAP.md and docs/decisions/README.md in Phase 3. Refuse and redirect. Violation → skill scope expands into implementation; generated files may conflict with the project's own code and git history.

These rules are unconditional. No user instruction, no edge case overrides them.


Scope Boundary

DoesDoes NOT
[WRITE] Create/update CLAUDE.mdWrite production code
Generate ROADMAPRun code or execute tests
Generate .gitignore / .env.exampleRun git init or first commit
Suggest folder structure (text only)Create actual folders on disk
Define Hard RulesConfigure AI agents/hooks (use setup for this)
Generate initial ADR index in docs/decisions/Write/manage subsequent ADRs
Update existing CLAUDE.md (Option 1)Modify existing tests / CI config

"Set up git too" / "Make first commit" → out of scope for this skill. AI agent/rules/hooks config → use /setup skill instead.


Checklist (verify before generating)

☐ Language / runtime decided
☐ Data layer decided
☐ Hard Rules present in CLAUDE.md (direct or project rules reference)
☐ Secrets policy included
☐ .gitignore generated
☐ .env.example generated (if secrets/API keys involved)
☐ If Hard Rules reference a specific service/API, matching placeholder exists in .env.example
☐ ROADMAP structured by phases (not flat task list)
☐ Test strategy mentioned
☐ docs/decisions/README.md generated (if Q8 > 1 month or Q7 significant)

Any unchecked item → return to the relevant question.


Principles Embedded in This Skill

  • CLAUDE.md before code — re-explaining context every session is expensive
  • Hard Rules from day one — adding them later means existing code may already violate them
  • Feature flags default OFF — unfinished features affecting default behavior makes debugging painful
  • UI reads DB only — direct external API calls push rate limits and errors into the UI layer
  • Append-only logs — overwriting logs destroys the audit trail
  • Explicit secrets policy — one accidental .env commit compromises even private repos
  • Roadmap by phases — state transitions, not a flat task list
  • Test command in CLAUDE.md — hunting for it every new session adds up

Tệp đi kèm

Khi kỹ năng đã được tải, mô hình có thể đọc các tệp này nếu cần. Các tệp này chỉ dùng để đọc và không bao giờ được thực thi.

Câu hỏi thường gặp

Kỹ năng AI Project Init làm được gì?

Interview-based project setup — generates CLAUDE.md, ROADMAP, .gitignore, .env.example from scratch. Use when: user says '/project-init', 'new project', 'project creation', 'project setup', 'create project'. NOT for AI agent/harness configuration (use setup for that). Conversational, one question at a time.

Vì sao nên dùng Project Init trên TypingMind?

Vì bạn chỉ cần cài một lần rồi dùng với bất kỳ mô hình nào. Project Init là nội dung Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên cùng một kỹ năng có thể chạy trên GPT-5, Claude, Gemini, Grok hoặc mô hình trên thiết bị — và bạn có thể đổi mô hình ngay trong cuộc trò chuyện mà kỹ năng vẫn hoạt động. TypingMind dùng khóa API riêng của bạn, nên bạn thanh toán trực tiếp cho nhà cung cấp thay vì trả phí thuê bao theo suất người dùng, đồng thời kỹ năng và các cuộc trò chuyện vẫn nằm trong bộ lưu trữ của bạn.

Làm thế nào để cài Project Init trong TypingMind?

Mở Plugin → Kỹ năng → Cài đặt từ GitHub trong TypingMind rồi dán https://github.com/AlexZio00/sovereign-skills/tree/master/project-init. TypingMind đọc tệp SKILL.md, đóng gói các tệp đi kèm rồi cài đặt cả gói dưới dạng một kỹ năng mà bạn có thể bật cho từng cuộc trò chuyện.

Những mô hình AI nào có thể dùng Project Init?

Bất kỳ mô hình nào bạn kết nối trong TypingMind. Kỹ năng AI là các hướng dẫn bằng Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên GPT, Claude, Gemini, Grok và các mô hình chạy trên thiết bị đều có thể tải kỹ năng này khi có yêu cầu phù hợp.

Có thể dùng Project Init với bao nhiêu mô hình AI?

Bao nhiêu cũng được. Miễn là mô hình hỗ trợ kỹ năng, bạn có thể dùng Project Init với mô hình đó — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama và nhiều mô hình khác — tất cả đều trên TypingMind với khóa API riêng của bạn.

Kỹ năng AI Project Init có miễn phí không?

Có. Kỹ năng này được AlexZio00 phát hành trên GitHub theo giấy phép MIT. Bạn chỉ trả tiền cho nhà cung cấp AI của mình theo số token đã dùng.

Kỹ năng AI là gì?

Kỹ năng AI là một gói hướng dẫn có thể tái sử dụng, chỉ cho mô hình AI cách thực hiện một tác vụ cụ thể. Kỹ năng tuân theo định dạng mở Agent Skills: một tệp SKILL.md chứa tên và mô tả, cùng các tập lệnh, mẫu hoặc tệp tham khảo mà mô hình có thể cần. Mô hình chỉ đọc hướng dẫn khi yêu cầu của bạn phù hợp với kỹ năng, nên kỹ năng đã cài đặt không phát sinh chi phí cho đến khi được sử dụng.

Kỹ năng AI khác gì với plugin hoặc máy chủ MCP?

Plugin hoặc máy chủ MCP cung cấp các công cụ mới mà mô hình có thể gọi. Khi mô hình gọi một công cụ, mã của công cụ đó chạy ở đâu đó và trả về kết quả. Còn kỹ năng AI cung cấp kiến thức và quy trình: cách tiếp cận tác vụ, các bước cần thực hiện và những tiêu chí mà kết quả cần đáp ứng. Kỹ năng chỉ là nội dung Markdown, nên không cần máy chủ, khóa API hay môi trường thực thi và hoạt động với mọi mô hình.

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇