Skip to content

Repository files navigation

AI Software Factory

AI Software Factory là framework phát triển phần mềm theo mô hình:

Idea → Context → Master Prompt → 15 SDLC Stages → Validation → Blueprint → AI Coding

Framework này model-agnostic, có thể vận hành thủ công với ChatGPT, Claude hoặc Qwen, sau đó tự động hóa bằng orchestrator/MCP khi quy trình đã ổn định.

Mục tiêu

  • Biến ý tưởng cấp cao thành bộ tài liệu có cấu trúc.
  • Progressive elaboration: business → product → domain → architecture → software.
  • Human approval tại các quyết định quan trọng.
  • Artifact là source of truth, không phụ thuộc conversation memory.
  • Traceability từ business goal đến requirement, design, task và test.
  • Tạo AI Coding Blueprint để giao cho AI coding agent.

Cấu trúc

ai-software-factory/
├── README.md
├── 00-framework/
│   ├── prompt-meta.md
│   ├── operating-principles.md
│   ├── decision-policy.md
│   ├── question-policy.md
│   ├── approval-policy.md
│   └── output-standard.md
├── 01-intake/
│   ├── idea-template.md
│   ├── context-intake.md
│   └── master-prompt-template.md
├── 02-stage-contracts/
│   ├── stage-contract.md
│   ├── input-contract.md
│   ├── output-contract.md
│   └── validation-contract.md
├── 03-sdlc/
│   ├── 01-product-vision.md
│   ├── 02-product-scope.md
│   ├── 03-business-analysis.md
│   ├── 04-stakeholder-user-analysis.md
│   ├── 05-product-requirements.md
│   ├── 06-domain-business-model.md
│   ├── 07-system-requirements.md
│   ├── 08-system-architecture.md
│   ├── 09-software-architecture.md
│   ├── 10-data-architecture.md
│   ├── 11-api-integration.md
│   ├── 12-security-authorization.md
│   ├── 13-ux-workflow.md
│   ├── 14-engineering-delivery.md
│   └── 15-software-blueprint.md
├── 04-validation/
│   └── validation-contract.md
├── 05-artifacts/
│   └── artifact-registry.md
└── examples/
    └── hrms-enterprise-vietnam/
        ├── 00-project-context.md
        ├── 01-master-prompt.md
        └── 02-start-project.md

Cách vận hành

Phase 1 — Intake

  1. Ghi ý tưởng vào 01-intake/idea-template.md.
  2. Chạy context-intake.md.
  3. Trả lời tối đa 5 câu hỏi.
  4. Chạy master-prompt-template.md.
  5. Review Master Prompt.

Phase 2 — 15 SDLC stages

Chạy tuần tự:

01 → 02 → 03 → 04 → 05 → 06 → 07 → 08
→ 09 → 10 → 11 → 12 → 13 → 14 → 15

Mỗi stage:

Input → Analyze → Question Gate → Generate Artifact
→ Validate → Human Approval → Handoff

Phase 3 — Blueprint

Stage 15 tổng hợp các artifact thành Software Blueprint.

Sau đó có thể tạo thêm:

Module Blueprint
Feature Specification
Task Specification
AI Coding Blueprint

Phase 4 — Coding

AI coding agent chỉ nhận:

  • coding context
  • relevant blueprint
  • module/feature specification
  • task
  • acceptance criteria
  • testing requirements

Không đưa toàn bộ conversation vào coding context.

Dùng với ChatGPT

Tạo một Project cho từng software project.

Đưa framework vào project knowledge/instructions. Mỗi stage tạo một chat hoặc artifact riêng.

Prompt khởi động:

Read the AI Software Factory framework.

Execute only the requested stage.
Respect the stage contract.
Do not skip dependencies.
Do not silently change approved decisions.
Ask up to 5 questions only when a blocking ambiguity exists.
Produce the required Markdown artifact.

Dùng với Claude

Tạo một Project cho từng software project.

Đưa framework vào project knowledge. Dùng Artifacts cho các tài liệu lớn nếu phù hợp, sau đó lưu bản chính thức vào repository.

Dùng với Qwen

Nên coi repository là source of truth.

Mỗi lần chạy stage cung cấp:

Prompt Meta
+ Stage Contract
+ Stage Prompt
+ Required Input Artifacts

Automation

Chỉ tự động hóa sau khi workflow thủ công ổn định.

Kiến trúc:

Orchestrator
    ↓
Prompt Compiler
    ↓
Agent
    ↓
Artifact
    ↓
Validator
    ↓
Human Gate
    ↓
Next Stage

MCP là tool-access layer, không thay thế SDLC. Có thể dùng MCP để kết nối Git, issue tracker, documentation, database hoặc môi trường phát triển.

Definition of Ready for Coding

[ ] Vision approved
[ ] Scope approved
[ ] Business analysis approved
[ ] Requirements approved
[ ] Domain model approved
[ ] System requirements approved
[ ] Architecture approved
[ ] Data architecture approved
[ ] API/integration approved
[ ] Security approved
[ ] UX/workflow approved
[ ] Engineering strategy approved
[ ] Traceability validated
[ ] No blocking open questions

Nguyên tắc vàng

Không code khi upstream specification chưa đủ rõ.

Không để conversation trở thành source of truth.

Artifact đã approved là contract cho stage tiếp theo.

AI đề xuất; Human quyết định các quyết định quan trọng.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors