Co-Pilot / 辅助式
更新于 2 months ago

hanoi-rainbow

DDauQuangThanh
0.0k
dauquangthanh/hanoi-rainbow
80
Agent 评分

💡 摘要

Hanoi Rainbow 通过 AI 助手简化项目创建和管理,支持以规范驱动的开发。

🎯 适合人群

寻求结构化项目管理的软件开发人员。希望改善开发工作流程的项目经理。从传统编码转向 AI 辅助开发的团队。希望快速开发 MVP 的初创公司。教授软件开发方法论的教育工作者。

🤖 AI 吐槽:看起来很能打,但别让配置把人劝退。

安全分析中风险

风险:Medium。建议检查:是否执行 shell/命令行指令;是否发起外网请求(SSRF/数据外发);API Key/Token 的获取、存储与泄露风险;文件读写范围与路径穿越风险。以最小权限运行,并在生产环境启用前审计代码与依赖。

🌈 Hanoi Rainbow

Drive Quality Together with AI-Powered Framework

Stop guessing. Start specifying.
Turn your ideas into production-ready applications through clear specifications, not trial-and-error coding.

Release GitHub stars License Documentation


Table of Contents

💡 What is Spec-Driven Development?

Traditional approach: Write code first, figure it out as you go.
Spec-Driven approach: Define what you want first, then let AI build it right.

For decades, we treated specifications as throwaway notes—just a formality before the "real" coding began. Spec-Driven Development flips this around: your specification becomes the blueprint that directly generates working code, not just a suggestion.

Think of it like architecture: You wouldn't build a house without blueprints. Why build software without clear specifications?

Development Approaches

Hanoi Rainbow supports both Greenfield (new projects) and Brownfield (existing projects) development:

flowchart LR Start([Project Type?]) Start --> Greenfield[🌱 Greenfield<br/>New Project] Start --> Brownfield[🏗️ Brownfield<br/>Existing Project] Greenfield --> GF1[📋 Regulate<br/>Set Principles] GF1 --> GF2[🎯 Specify<br/>Define Features] GF2 --> GF3[🔍 Clarify<br/>Refine Requirements] GF3 --> GF4[📝 Architect<br/>System Design] GF4 --> GF5[📏 Standardize<br/>Coding Rules] GF5 --> GF6[🛠️ Design<br/>Technical Plan] GF6 --> GF7[📋 Taskify<br/>Break Down Tasks] GF7 --> GF8[⚡ Implement<br/>Build Features] GF8 --> GF9[✅ Test & Deploy] Brownfield --> BF1[📚 Assess Context<br/>Analyze Codebase] BF1 --> BF2[📋 Regulate<br/>Update Principles] BF2 --> BF3[🎯 Specify<br/>New Feature] BF3 --> BF4[🔍 Clarify<br/>Requirements] BF4 --> BF5[🛠️ Design<br/>Integration Plan] BF5 --> BF6[📋 Taskify<br/>Task Breakdown] BF6 --> BF7[⚡ Implement<br/>Add Feature] BF7 --> BF8[✅ Test & Deploy] style Greenfield fill:#90EE90 style Brownfield fill:#87CEEB style GF8 fill:#FFD700 style BF7 fill:#FFD700

Greenfield projects start with establishing principles, architecture, and standards before building features. Brownfield projects begin with /rainbow.assess-context to understand existing architecture and patterns, then follow a streamlined workflow to add new features while maintaining consistency.

Key Differences:

| Aspect | 🌱 Greenfield | 🏗️ Brownfield | |--------|--------------|---------------| | Starting Point | Empty project | Existing codebase | | Setup Phase | /rainbow.regulate | /rainbow.assess-context (once per project) | | Focus | Establish foundations first | Integrate with existing patterns | | Timeline | 2-4 weeks (MVP) | 1-2 weeks per feature | | Flexibility | Complete freedom in design | Must maintain consistency | | Commands Used | Full workflow (8 core commands) | Streamlined (6 core commands) |

Install Rainbow CLI

Recommended: Install once, use everywhere

uv tool install rainbow-cli --from git+https://github.com/dauquangthanh/hanoi-rainbow.git

Then use it anywhere:

rainbow init <PROJECT_NAME> rainbow check

Need to upgrade? See the Upgrade Guide or run:

uv tool install rainbow-cli --force --from git+https://github.com/dauquangthanh/hanoi-rainbow.git
uv tool install rainbow-cli --force --native-tls --from git+https://github.com/dauquangthanh/hanoi-rainbow.git
uvx --from git+https://github.com/dauquangthanh/hanoi-rainbow.git rainbow init <PROJECT_NAME>
uvx --native-tls --from git+https://github.com/dauquangthanh/hanoi-rainbow.git rainbow init <PROJECT_NAME>

Why install?

  • ✅ Available everywhere in your terminal
  • ✅ Easy to upgrade with uv tool upgrade
  • ✅ Cleaner than shell aliases
  • ✅ Better tool management

Your First Project in 8 Steps

💡 Automatic Version Control: All Rainbow commands automatically generate appropriate git commit messages and commit changes upon completion. Commands use semantic commit prefixes (docs:, feat:, test:, chore:) to maintain a clear project history.

1️⃣ Set Project Rules

Launch your AI assistant in the project. You'll see /rainbow.* commands available.

Create your project's guiding principles:

/rainbow.regulate Create principles for code quality, testing, user experience, and performance

2️⃣ Write the Specification

Describe what you want to build and why (not the tech stack yet):

/rainbow.specify Build a photo organizer with albums grouped by date. Users can drag-and-drop albums to reorganize them. Albums show photos in a tile view. No nested albums allowed.

3️⃣ Design System Architecture (Optional)

Document your system architecture once per product:

/rainbow.architect Create C4 diagrams, document tech stack decisions and architecture patterns

4️⃣ Set Coding Standards (Optional)

Create coding standards for your team:

/rainbow.standardize Define naming conventions, file organization, and best practices

5️⃣ Create Technical Design

Now specify how to build it (tech stack and architecture):

/rainbow.design Use Vite with vanilla HTML, CSS, and JavaScript. Keep libraries minimal. Store metadata in local SQLite. No image uploads.

6️⃣ Break Down Tasks

Generate an actionable task list:

/rainbow.taskify

7️⃣ Build It

Execute all tasks automatically:

/rainbow.implement

8️⃣ Test & Iterate

Run your application and fix any issues. Your AI assistant will help debug.


Want more details? Read our complete guide.

🤖 Supported AI Agents

| Agent | Support | Notes | | ----------------------------------------------------------- | --------- |---------------------------------------------------| | Amazon Q Developer CLI | ⚠️ | Amazon Q Developer CLI does not support custom arguments for slash commands. | | Amp | ✅ | | | Auggie CLI | ✅ | | | Claude Code | ✅ | | | CodeBuddy CLI | ✅ | | | Codex CLI | ✅ | | | Cursor | ✅ | | | Gemini CLI | ✅ | | | GitHub Copilot | ✅ | | | Google Antigravity | ✅ | IDE-based agent with slash command support | | IBM Bob | ✅ | IDE-based agent with slash command support | | Jules | ✅ | | | Kilo Code | ✅ | | | opencode | ✅ | | | Qoder CLI | ✅ | | | Qwen Code | ✅ | | | Roo Code | ✅ | | | SHAI (OVHcloud) | ✅ | | | Windsurf | ✅ | |

🔧 Rainbow CLI Reference

The rainbow command supports the following options:

Commands

| Command | Description | | ------------- | ---------------------------------------------------------------- | | `init

五维分析
清晰度8/10
创新性8/10
实用性9/10
完整性8/10
可维护性7/10
优缺点分析

优点

  • 促进清晰的项目规范。
  • 集成 AI 助手进行开发。
  • 支持新项目和现有项目。
  • 自动化版本控制和任务管理。

缺点

  • 新用户可能需要学习曲线。
  • 对 AI 的依赖可能限制创造力。
  • 管理现有代码库的复杂性。
  • 可能过度依赖自动化。

相关技能

pytorch

S
toolCode Lib / 代码库
92/ 100

“它是深度学习的瑞士军刀,但祝你好运能从47种安装方法里找到那个不会搞崩你系统的那一个。”

agno

S
toolCode Lib / 代码库
90/ 100

“它承诺成为智能体领域的Kubernetes,但得看开发者有没有耐心学习又一个编排层。”

nuxt-skills

S
toolCo-Pilot / 辅助式
90/ 100

“这本质上是一份组织良好的小抄,能把你的 AI 助手变成一只 Nuxt 框架的复读机。”

免责声明:本内容来源于 GitHub 开源项目,仅供展示和评分分析使用。

版权归原作者所有 DauQuangThanh.