design — команда для Claude Code: что делает и как установить
Команда design проектирует архитектуру систем, схемы баз данных и спецификации API перед написанием кода. Пригодится на этапе планирования сервисов.
MIT ★ 23 950 обновлён 2026-09-27
.claude/commands/design.mdЧто делает design
Команда анализирует контекст репозитория и составляет спецификацию по стандартам разработки. Для изучения кодовой базы запускается поиск через grep или glob. Внешние утилиты вызываются через bash.
Формат задаётся ключами --type и --format. Доступны типы архитектуры, API, компонентов или баз данных. На выходе формируются документы с диаграммами потоков данных и описанием интерфейсов.
Рабочий код компонентов команда не пишет. Она фиксирует системные контракты и ограничения. Для написания кода автор предлагает вызывать /sc:implement.
Какие задачи решает
- спроектировать архитектуру сервиса с диаграммами связей
- описать контракт эндпоинтов RESTful или GraphQL
- составить схему базы данных с таблицами и связями
- определить интерфейсы и границы отдельного компонента
Примеры запросов агенту
- /sc:design
user-management-system --type architecture --format diagram - /sc:design
payment-api --type api --format spec - /sc:design
e-commerce-db --type database --format diagram
Как установить design
Вручную: положить файлы
.claude/commands/design.mdВызов — /design. Для всех проектов — ~/.claude/commands/
Вручную: положить файлы
~/.codex/prompts/design.mdВызов — /prompts:design. В Codex этот формат помечен устаревшим, замена — скиллы
Вручную: положить файлы
.github/prompts/design.prompt.mdВручную: положить файлы
.gemini/commands/design.tomlGemini хранит команды в TOML: текст запроса — в поле prompt
Вопросы о design
Как установить design в Claude Code?
Сохраните файл команды по пути .claude/commands/design.md. После добавления файла вызов сразу станет доступен в сессии Claude Code.
Для чего нужна команда /sc:design?
Она создаёт технические спецификации, диаграммы компонентов и структуры баз данных до начала программирования. Это помогает спланировать масштабируемость системы.
Пишет ли команда готовый код реализации?
Нет, команда создаёт только проектную документацию, схемы и интерфейсы. Чтобы написать сам код по созданной спецификации, используйте команду /sc:implement.
Исходный текст
design.md · MIT
--- name: design description: "Design system architecture, APIs, and component interfaces with comprehensive specifications" category: utility complexity: basic mcp-servers: [] personas: [] --- # /sc:design - System and Component Design ## Triggers - Architecture planning and system design requests - API specification and interface design needs - Component design and technical specification requirements - Database schema and data model design requests ## Usage ``` /sc:design [target] [--type architecture|api|component|database] [--format diagram|spec|code] ``` ## Behavioral Flow 1. **Analyze**: Examine target requirements and existing system context 2. **Plan**: Define design approach and structure based on type and format 3. **Design**: Create comprehensive specifications with industry best practices 4. **Validate**: Ensure design meets requirements and maintainability standards 5. **Document**: Generate clear design documentation with diagrams and specifications Key behaviors: - Requirements-driven design approach with scalability considerations - Industry best practices integration for maintainable solutions - Multi-format output (diagrams, specifications, code) based on needs - Validation against existing system architecture and constraints ## Tool Coordination - **Read**: Requirements analysis and existing system examination - **Grep/Glob**: Pattern analysis and system structure investigation - **Write**: Design documentation and specification generation - **Bash**: External design tool integration when needed ## Key Patterns - **Architecture Design**: Requirements → system structure → scalability planning - **API Design**: Interface specification → RESTful/GraphQL patterns → documentation - **Component Design**: Functional requirements → interface design → implementation guidance - **Database Design**: Data requirements → schema design → relationship modeling ## Examples ### System Architecture Design ``` /sc:design user-management-system --type architecture --format diagram # Creates comprehensive system architecture with component relationships # Includes scalability considerations and best practices ``` ### API Specification Design ``` /sc:design payment-api --type api --format spec # Generates detailed API specification with endpoints and data models # Follows RESTful design principles and industry standards ``` ### Component Interface Design ``` /sc:design notification-service --type component --format code # Designs component interfaces with clear contracts and dependencies # Provides implementation guidance and integration patterns ``` ### Database Schema Design ``` /sc:design e-commerce-db --type database --format diagram # Creates database schema with entity relationships and constraints # Includes normalization and performance considerations ``` ## Boundaries **Will:** - Create comprehensive design specifications with industry best practices - Generate multiple format outputs (diagrams, specs, code) based on requirements - Validate designs against maintainability and scalability standards **Will Not:** - Generate actual implementation code (use /sc:implement for implementation) - Modify existing system architecture without explicit design approval - Create designs that violate established architectural constraints **Output**: Architecture documents containing: - System diagrams (component, sequence, data flow) - API specifications - Database schemas - Interface definitions **Next Step**: After design is approved, use `/sc:implement` to build the designed components.
© SuperClaude-Org · MIT · SuperClaude-Org/SuperClaude_Framework