원클릭으로
aggregate-platform-architecture
// Combine multiple component architecture summaries into a platform-level architecture document. Use after generating component summaries to create a wholistic platform view.
// Combine multiple component architecture summaries into a platform-level architecture document. Use after generating component summaries to create a wholistic platform view.
Analyze a component repository and generate comprehensive architecture summary with structured markdown tables. Use when analyzing ODH/RHOAI components, documenting architecture, or creating security diagrams.
Discover platform components by exploring breadcrumbs (installers, operators, dependencies) in checkouts directory. Outputs component-map.json for platforms without manifest scripts.
Generate architecture diagrams (Mermaid, C4, security network diagrams) from GENERATED_ARCHITECTURE.md. Creates visual representations for different audiences - developers, architects, security teams.
Generate diagrams for all component architecture files in an organized architecture directory. Processes each component sequentially ONE AT A TIME by reading the .md file and extracting data from tables. Creates Mermaid, C4, and security diagrams. Skips components that already have diagrams by default.
Generate platform-level diagrams (dependency graphs, network topology, cross-component workflows) from aggregated PLATFORM.md file. Creates visualizations for architects, security teams, and platform engineers.
Analyze all components for a platform (ODH or RHOAI) sequentially by parsing get_all_manifests.sh and executing repo-to-architecture-summary for each. Skips components that already have GENERATED_ARCHITECTURE.md. Fully autonomous and resumable.
| name | aggregate-platform-architecture |
| description | Combine multiple component architecture summaries into a platform-level architecture document. Use after generating component summaries to create a wholistic platform view. |
| allowed-tools | Read, Glob, Grep, Write, Bash(ls *), Bash(find *), Bash(python *), Bash(*/arch-query *) |
Combine component architecture summaries into a comprehensive platform-level architecture document focused on synthesis and cross-cutting analysis.
Required:
--platform-dir=<path> - Path to the platform directory containing component .md files (e.g., architecture/rhoai)Optional:
--distribution=NAME - Distribution name (e.g., rhoai, odh). Default: derived from directory name.--version=VERSION - Platform version string. Default: unknown.--generated-by=STRING - Exact string for the "Generated By" metadata field (e.g., Claude Opus 4.6). Default: auto-detect model name + current date.--output=FILENAME (default: PLATFORM.md)When invoked by the orchestrator, all arguments are provided on the command line. When invoked manually, only --platform-dir is required.
IMPORTANT - TOOL USAGE:
ToolSearch. You already have access to: Bash, Read, Write, Glob, Grep.arch-query via Bash for structured data extraction — do NOT manually read and parse component markdown files.Extract all structured platform data in a single command:
arch-query platform-summary --base-dir={architecture_base_dir} --version={version_dir_name} --output json
Where:
{architecture_base_dir} is the parent of {platform_dir} (e.g., if --platform-dir=/data/architecture/rhoai.next, use --base-dir=/data/architecture){version_dir_name} is the directory name (e.g., rhoai.next)This returns a single JSON object containing all components, CRDs, services, endpoints, dependencies, RBAC, controller watches, network policies, and dockerfiles — already aggregated across all components. You do NOT need to read individual component files to get this data.
If arch-query is not available, fall back to reading component files directly (see Fallback section below).
Using the JSON data from Step 1, analyze cross-cutting patterns.
First, generate the deterministic dependency tree:
arch-query deps --base-dir={architecture_base_dir} --version={version_dir_name}
This produces a tree-list showing how the operator deploys and connects all components, with relationship annotations (deploys, CRD watch, manages, API, etc.). Use this output verbatim as the dependency graph in the "Component Relationships > Dependency Graph" section of PLATFORM.md — do NOT generate your own ASCII diagram or box-style graph. The tree-list format with |-- prefixes and parenthetical annotations is the canonical format.
Then analyze from the JSON data:
Central components: From the tree + internal_deps, identify components with the most reverse dependencies (other components pointing at them).
Integration patterns: From internal_deps and services, identify recurring integration patterns (e.g., CRD-based orchestration, gRPC service mesh, REST API composition).
Namespace topology: From component metadata and services, determine how components are deployed across namespaces.
Authentication patterns: From component metadata, identify which auth mechanisms are used and by which components (Bearer tokens, mTLS, kube-rbac-proxy, etc.).
Container security patterns: From dockerfiles data, identify common patterns (non-root execution, FIPS compliance, UBI base images, capability drops).
HA patterns: From component metadata, identify replication and leader election patterns.
For synthesis that requires the free-form prose from component docs, selectively read the "Architectural Analysis" sections from key components. Use arch-query component <name> --base-dir={architecture_base_dir} --output raw to read specific components, or grep for analysis sections:
grep -l "Architectural Analysis" {platform_dir}/*.md
Then read only those sections from the most architecturally significant components (operators, controllers, core services). Do NOT read every component file — focus on components identified as central in Step 2.
Identify 3-5 key platform workflows by tracing dependency chains and service interactions from the structured data. For each workflow:
Follow the template exactly as defined in platform template. Read that file before writing.
Structural rules:
# Platform: [Distribution Name] [Version]## Version-Specific Changes ([version]) section heading includes the version in parenthesesWhat PLATFORM.md is NOT:
arch-query and the component .md/.json files.Populate the "Generated By" field in the Metadata section:
--generated-by was provided, use that exact string followed by on YYYY-MM-DD (use date +%Y-%m-%d to get the date) on YYYY-MM-DDWrite the output file to {platform_dir}/{output_filename}.
After writing, run the validation script:
python ${CLAUDE_SKILL_DIR}/scripts/validate_platform.py {platform_dir}/PLATFORM.md
If validation fails, read the errors, fix the markdown, re-write the file, and re-validate. Do not proceed to Step 7 until validation passes.
Output a summary:
Platform architecture aggregated!
Distribution: {distribution}
Version: {version}
Components analyzed: {count}
File created: {platform_dir}/PLATFORM.md
Summary:
- {N} components analyzed
- {N} integration patterns identified
- {N} key workflows documented
- {N} namespaces mapped
- {N} security patterns identified
If arch-query is not available (command not found), fall back to reading component files:
.md files: find {platform_dir} -maxdepth 1 -name "*.md" -type f ! -name "README.md" ! -name "PLATFORM.md" | sortThis is slower but produces the same result.
.md and .json files and is queryable via arch-query.