Agent SkillsHouseofmvps/ultraship › architecture

architecture

GitHub

自动扫描代码库生成 Mermaid 架构图,涵盖系统结构、API路由、数据库及数据流。提供架构分析以识别循环依赖等隐患,并输出文档与优化建议,确保文档实时准确。

skills/architecture/SKILL.md Houseofmvps/ultraship

Trigger Scenarios

需要可视化代码库架构 理解代码整体结构 生成系统设计方案图 进行代码架构健康度分析

Install

npx skills add Houseofmvps/ultraship --skill architecture -g -y
More Options

Use without installing

npx skills use Houseofmvps/ultraship@architecture

指定 Agent (Claude Code)

npx skills add Houseofmvps/ultraship --skill architecture -a claude-code -g -y

安装 repo 全部 skill

npx skills add Houseofmvps/ultraship --all -g -y

预览 repo 内 skill

npx skills add Houseofmvps/ultraship --list

SKILL.md

Frontmatter
{
    "name": "architecture",
    "description": "Living Architecture Map — auto-generate Mermaid diagrams of your codebase. Use when user wants to visualize architecture, understand code structure, generate diagrams, or document system design.",
    "allowed-tools": "Bash, Read, Grep, Glob, Write"
}

Living Architecture Map

Auto-generates and maintains architecture diagrams from your actual code. Always up-to-date.

Process

Phase 1: Scan

node ${CLAUDE_PLUGIN_ROOT}/tools/architecture-mapper.mjs <project-directory>

Parse the JSON output for architecture data and diagrams.

Phase 2: Present Diagrams

Display each Mermaid diagram with context:

System Architecture: High-level view of all components and how they connect.

[system diagram from tool output]

API Route Map: All endpoints organized by resource.

[routes diagram from tool output]

Database Schema: Entity-relationship diagram of all tables and relations.

[database ER diagram from tool output]

Data Flow: Sequence diagram showing how a typical request flows through the system.

[data flow diagram from tool output]

Phase 3: Architecture Analysis

Based on the scanned data, provide analysis:

Strengths:

  • Clear layer separation
  • No circular dependencies
  • Well-organized middleware chain

Concerns:

  • Circular dependencies found (list them)
  • Orphan modules (files imported by nothing)
  • Large files that may need splitting
  • Missing middleware (no auth, no rate limiting, etc.)

Service Dependencies: List all external services and how they're used. Flag any that are single points of failure.

Phase 4: Save Diagrams

Save architecture documentation:

  1. Create docs/architecture/ directory
  2. Save docs/architecture/ARCHITECTURE.md with all diagrams
  3. Save individual diagram files if needed

The document should be self-contained and renderable in GitHub (GitHub supports Mermaid in markdown).

Phase 5: Recommendations

Based on architecture analysis:

  1. Circular dependencies — suggest how to break cycles
  2. Orphan modules — suggest removal or integration
  3. Missing patterns — suggest middleware, error handling, or caching if absent
  4. Scalability concerns — identify bottlenecks (single database, no caching, synchronous processing)

Keeping Diagrams Updated

Recommend running /architecture after any significant structural change:

  • Adding new API routes
  • Adding new database tables
  • Integrating new external services
  • Major refactors

The diagrams are generated from code, so they're always accurate when re-run.

Key Principle

The map IS the territory. Architecture diagrams that drift from reality are worse than no diagrams. Because these are auto-generated from code, they're always truthful.

Version History

  • ed232cb Current 2026-07-24 16:14

Same Skill Collection

skills/a11y/SKILL.md
skills/brainstorming/SKILL.md
skills/canary/SKILL.md
skills/clone-patterns/SKILL.md
skills/code-review/SKILL.md
skills/compete/SKILL.md
skills/cost/SKILL.md
skills/demo/SKILL.md
skills/deploy/SKILL.md
skills/dispatching-parallel-agents/SKILL.md
skills/evals/SKILL.md
skills/executing-plans/SKILL.md
skills/finishing-a-development-branch/SKILL.md
skills/frontend-design/SKILL.md
skills/grow/SKILL.md
skills/guard/SKILL.md
skills/index-fix/SKILL.md
skills/investigate/SKILL.md
skills/launch/SKILL.md
skills/learn/SKILL.md
skills/onboard/SKILL.md
skills/pentest/SKILL.md
skills/perf-audit/SKILL.md
skills/receiving-code-review/SKILL.md
skills/release/SKILL.md
skills/requesting-code-review/SKILL.md
skills/rescue/SKILL.md
skills/retro/SKILL.md
skills/revise-claude-md/SKILL.md
skills/security-audit/SKILL.md
skills/seo-audit/SKILL.md
skills/seo-strategy/SKILL.md
skills/ship-gate/SKILL.md
skills/sprint/SKILL.md
skills/staying-current/SKILL.md
skills/subagent-driven-development/SKILL.md
skills/systematic-debugging/SKILL.md
skills/test-driven-development/SKILL.md
skills/using-git-worktrees/SKILL.md
skills/using-ultraship/SKILL.md
skills/verification-before-completion/SKILL.md
skills/visual-diff/SKILL.md
skills/writing-plans/SKILL.md
skills/writing-skills/SKILL.md

Metadata

Files
0
Version
ed232cb
Hash
9e8c7a1f
Indexed
2026-07-24 16:14

inicio - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-16 20:12
浙ICP备14020137号-1 $mapa de visitantes$