🏗️physical-ai-infrastructure-setup-and-resilient-scaling
- プラグイン
- nvidia-skills
- ライセンス
- Apache-2.0
- ソース
- GitHub で見る ↗
説明
次のような場合に使用: ユーザーが、ローカルの MicroK8s または Azure AKS 上での合成データ生成(SDG)ワークフローを対象に、NVIDIA Physical AI インフラのセットアップ・スケーリング・検証・堅牢化を行いたい場合。 対象範囲には、Kubernetes クラスター、推論エンドポイントのデプロイ、OSMO のデプロイ、ワークロード投入の準備確認、およびインフラ障害からの復旧が含まれます。 **トリガーキーワード:** `physical ai infrastructure`、`resilient scaling`、`SDG infrastructure`、`microk8s`、`azure aks`、`NVCF deployment`、`NIM Operator`、`OSMO deploy`、`workflow scaling` **トリガー対象外:** OSMO のログ要約や、ワークロード単体の操作(インフラのセットアップ・スケーリング・検証・復旧が明示的に要求されていない場合)。
原文を表示
Use when the user wants to set up, scale, validate, or harden NVIDIA physical AI infrastructure for synthetic data generation workflows across local MicroK8s or Azure AKS, including Kubernetes clusters, inference endpoint deployment, OSMO deployment, workload submission readiness, and infrastructure failure recovery. Trigger keywords: physical ai infrastructure, resilient scaling, SDG infrastructure, microk8s, azure aks, NVCF deployment, NIM Operator, OSMO deploy, workflow scaling. Don't trigger for: OSMO log summarization or workload-only operations unless infrastructure setup, scaling, validation, or recovery is requested.
ユースケース
- ✓MicroK8sまたはAzure AKS上でのセットアップ
- ✓SDGワークフロー向けインフラスケーリング
- ✓Physical AIインフラの検証・堅牢化
- ✓推論エンドポイントのデプロイ
- ✓インフラ障害からの復旧
本文(日本語訳)
Physical AI インフラセットアップと耐障害性スケーリング
Physical AI インフラスタックのカノニカルスキルです。 クラスター、推論(inference)、OSMO、ワークロードの各ステージを組み合わせて 再現性のある Physical AI SDG 環境を構築し、その環境の可観測性と回復性を維持します。
動作ルール
- 選択したターゲットに必要なコンポーネントリファレンスのみを読み込むこと。 デフォルトですべてのコンポーネントをロードしないこと。
- リポジトリを永続的な成果物として扱うこと。チェックイン済みの設定やスクリプトを修正してから再実行する。 追跡されていない一時的な変更でインストール失敗を回復しないこと。
- スクリプトが存在する場合は、クラスター・OSMO・Helm・Terraform・Azure の変更操作を チェックイン済みスクリプト経由で実行すること。読み取り専用の診断は許可。
- 最初のレッドゲートで停止すること。以下の順序で最下位の所有レイヤーから修正する: 設定 → スクリプト → スキルガイダンス。
- 可能な限り環境から値を導出すること。APIキー・ターゲット選択・クォータのトレードオフなど、 推論できない値のみ確認を求める。
- シークレットは
${REPO_ROOT}/.envに保存すること。 ストレージ・データベース・Redis・エンドポイント名などのクラスター由来の値は、 Terraform のアウトプットまたはプラットフォームクエリから取得し、.envには含めない。 - プリフライトとはデプロイ済み状態が存在しない状態を意味する: クラスター API・Terraform アウトプット・ Helm リリース・OSMO プール・ワークフロー状態はいずれも存在しない。 これらはデプロイ/検証ゲートに属する。
- 生のキーをコマンド・YAML・ログ・トランスクリプトに出力・エコー・貼り付けしないこと。
クレデンシャルハンドル・Kubernetes の
secretKeyRef・ランタイム限定のシークレット注入を優先する。 共有前にトランスクリプトの生エクスポートをscripts/scan_transcript_secrets.pyでスキャンすること。 - 絶対パスを使用すること。リポジトリルートは
git rev-parse --show-toplevelで導出する。
コンポーネントリファレンス
スタックに単一のカノニカルトリガーを持たせるため、各コンポーネントはこのスキル内に存在します。 選択したターゲットがそのスライスを必要とする場合にのみ、対応するコンポーネントリファレンスをロードしてください。
| 関心領域 | ロード対象 | アセット |
|---|---|---|
| ステージマトリクスおよび旧ドライバーノート | components/driver/reference.md |
なし |
| MicroK8s クラスター | components/cluster-microk8s/reference.md |
components/cluster-microk8s/scripts/、components/cluster-microk8s/runtimeclass-nvidia-runc.yaml |
| Azure AKS クラスター | components/cluster-azure/reference.md |
components/cluster-azure/scripts/、components/cluster-azure/terraform/ |
| NIM Operator 推論 | components/inference-nim-operator/reference.md |
components/inference-nim-operator/scripts/、components/inference-nim-operator/nims/ |
| NVCF 推論 | components/inference-nvcf/reference.md |
components/inference-nvcf/scripts/ |
| Azure AI Foundry 推論 | components/inference-azure/reference.md |
components/inference-azure/scripts/ |
| MicroK8s OSMO | components/osmo-k8s/reference.md |
components/osmo-k8s/scripts/、アップストリーム OSMO デプロイスクリプト |
| Azure OSMO | components/osmo-azure/reference.md |
components/osmo-azure/scripts/、アップストリーム OSMO デプロイスクリプトおよび Azure TF アウトプット |
| Azure アクセス設定 | components/azure-access/reference.md |
なし |
| OSMO CLI およびワークフロー操作 | components/osmo-cli/reference.md |
components/osmo-cli/scripts/、components/osmo-cli/references/、components/osmo-cli/agents/、components/osmo-cli/tests/ |
| OpenClaw Azure デバイスログイン | components/openclaw-azure-login/reference.md |
なし |
OSMO CLI サポートファイル
OSMO CLI コンポーネントは、コマンドおよびワークフロー操作の範囲が広いため、 第2レベルのサポートファイルを持ちます。以下のファイルは、記載されたケースにのみ直接ロードしてください。
| ファイル | 読み込むタイミング |
|---|---|
components/osmo-cli/agents/workflow-expert.md |
ワークフロー生成またはワークフロー失敗のサブエージェントを起動する場合。 |
components/osmo-cli/agents/logs-reader.md |
OSMO ワークフロー失敗のログ要約サブエージェントを起動する場合。 |
components/osmo-cli/references/cli-commands.md |
OSMO CLI の正確なフラグ・ペイロード・コマンド構文が必要な場合。 |
components/osmo-cli/references/workflow-spec.md |
ワークフロー YAML スキーマ・クレデンシャル・アウトプット・プロバイダーフィールドが必要な場合。 |
components/osmo-cli/references/workflow-patterns.md |
マルチタスク・データ依存・Jinja・シリアル・パラレルのワークフロー設計が必要な場合。 |
components/osmo-cli/references/advanced-patterns.md |
チェックポイント・リトライ/終了動作・ノード除外が必要な場合。 |
components/osmo-cli/tests/orchestrator-runtime-failure.md |
OSMO オーケストレーションレビューパターンの検証またはデバッグを行う場合。 |
ターゲット選択
各ステージにつき選択肢を1つだけ選ぶこと。ステージ2はステージ1の後に続きます。
- Kubernetes:
MicroK8sまたはAzure - OSMO: Kubernetes が MicroK8s の場合は
MicroK8s OSMO、Azure の場合はAzure OSMO - 推論:
NIM Operator・NVCF・Azure AI Foundry・またはNone - ワークロード: Video Data Augmentation・Defect Image Generation・NuRec Carline Adaptation・ NRE・NCore・Asset Harvester・またはカスタムワークフロー YAML
プロビジョニング前に無効な組み合わせを拒否すること:
| クラスター | NIM Operator | NVCF | Azure AI Foundry |
|---|---|---|---|
| MicroK8s | 可 | 可 | 不可(Foundry は Azure ID が必要) |
| Azure | 可 | 可 | 可 |
ブラウザを開けない OpenClaw またはチャット専用環境の場合は、
Azure 前提条件の前に components/openclaw-azure-login/reference.md を読み込むこと。
Azure ターゲットの場合は、Azure コンポーネントのプリフライト前に
components/azure-access/reference.md を読み込むこと。
セットアップフロー
- ターゲットの選択内容とワークロードのコンピュート要件を確認する。
- 選択したコンポーネントリファレンスをロードする。
- APIキー・Azure アクセス・呼び出し元 CIDR・GPU クォータ・ストレージクラス・ OSMO ログイン要件などの前提条件を事前にすべて解決する。
- プロビジョニング前に、選択した各インフラコンポーネントおよび OSMO CLI/ワークロードのプリフライトに対して
scripts/preflight.shを実行する。結果から実装計画を構築し、プリフライトがレッドの場合は停止する。 - まず Kubernetes をデプロイする。クラスターゲートがグリーンになるまで他の処理は開始しない。
- Kubernetes の後に OSMO と推論をデプロイする。クラスターが存在すれば並行して進められるが、 ワークロードの投入は選択した両ゲートの完了を待つ。
- OSMO・ストレージクレデンシャル・コンピュートプール・選択した推論エンドポイントがすべて検証された後にのみ
ワークロードを投入する。VDA の場合は、
preflight_credentials.sh・解決済みの--set値を使ったpre_submit_guard.py・空でないモデルキャッシュプレフィックス・ ワークフロー名前空間のエンドポイントスモークチェックも含む。 - 完了までモニタリングを続ける。ワークフロー状態が失敗した場合は、
components/osmo-cli/reference.mdからイベントとログを確認する。 確認せずに再投入しないこと。
推論ディスカバリー
コストのかかるエンドポイントの過剰デプロイを避けること。
- 選択したワークフロースペックとデフォルト値をスキャンして、以下のエンドポイント参照を探す:
*.osmo-nims.svc.cluster.local・api.nvcf.nvidia.com/*・*.inference.ai.azure.com・*.cognitiveservices.azure.com - 各参照を選択したバックエンドにマッピングする:
- NIM Operator: サービス名が
components/inference-nim-operator/nims/配下のディレクトリと一致する必要がある。 - NVCF: 関数 URL または関数 ID は環境から提供される必要がある。
- Azure AI Foundry: エンドポイント名は
components/inference-azure/scripts/install.shを通じて デプロイされている必要がある。
- NIM Operator: サービス名が
- ワークフローが選択したバックエンドで対応できない機能を必要とする場合は、停止してミスマッチを報告する。 別のモデルへの暗黙の代替は行わないこと。
検証ゲート
各ステージにはコンポーネントリファレンス内に専用の「検証」セクションがあります。 以下のゲートは必須です:
| ステージ | ゲート |
|---|---|
| Kubernetes | クラスター API に到達可能、ノードが Ready 状態、GPU パスでは GPU キャパシティが通知済み、CPU+NVCF パスでは runtimeclass/nvidia が runc にマッピング済み。 |
| 推論 | ワークロードが参照するすべてのエンドポイントに到達可能。NIM のレディネスは /v1/health/ready を使用。NVCF と Foundry はタスク固有の認証済みチェックが別途必要。 |
| OSMO | OSMO Pod が Ready 状態、プールが ONLINE、ポートフォワードのウォッチドッグが稼働中、ストレージクレデンシャルが設定済み、verify-hello ワークフローが COMPLETED。 |
| ワークロード | 選択したワークロードの投入前ガードが投入前にパスすること。osmo workflow query <id> が COMPLETED を報告し、すべてのタスクがグリーンであること。失敗した終端状態ではリトライ前にイベントとログの確認が必要。 |
耐障害性スケーリング
- プロビジョニング前にワークロードの要件からクラスターサイズを決定する。
Azure の場合は
terraform apply前に選択した VM ファミリーの CPU および GPU クォータを確認する。 - NIM Operator の場合は、ワークロードが参照する NIMService のみをデプロイする。 各サービスはクラスターの存続期間中、GPU とモデルキャッシュストレージを占有する。
- OSMO のストレージ URL スキームをアクティブなバックエンドと一致させること。 ローカル MicroK8s は MinIO を使用し、Azure は Blob バックの設定を使用する。
- Pending・Unknown・ImagePullBackOff・アンバインドの PVC・0 Ready レプリカはレイヤー障害として扱う。 同じコマンドを再試行する前に、スケジューリング・ストレージ・イメージクレデンシャル・ 隣接するプラットフォーム状態を調査すること。
- 長時間のデプロイやワークフロー監視では、現在の状態・経過時間・最後に有益な観察内容・ 次回チェック予定を含むハートビートアップデートを提供すること。
ワークロードルーティング
- Video Data Augmentation:
skills/physical-ai-video-data-augmentation/SKILL.md
原文(English)を表示
Physical AI Infrastructure Setup And Resilient Scaling
Canonical skill for the Physical AI infrastructure stack. Use it to compose cluster, inference, OSMO, and workload stages into a reproducible Physical AI SDG environment, then keep the environment observable and recoverable.
Operating Rules
- Read only the component references needed for the selected target. Do not load every component by default.
- Keep the repo as the durable artifact. Fix checked-in config or scripts, then rerun. Do not recover a failed install with untracked one-off changes.
- Run mutating cluster, OSMO, Helm, Terraform, or Azure operations through checked-in scripts when a script exists. Read-only diagnostics are allowed.
- Stop at the first red gate. Fix the lowest owning layer in this order: config, script, then skill guidance.
- Derive values from the environment when possible. Ask only for values that cannot be inferred, such as API keys, target choice, or quota tradeoffs.
- Store secrets in
${REPO_ROOT}/.env. Cluster-derived values such as storage, database, Redis, and endpoint names come from Terraform outputs or platform queries, not.env. - Preflight means no deployed state: no cluster API, Terraform outputs, Helm releases, OSMO pools, or workflow state. Those belong to deploy/verify gates.
- Never print, echo, or paste raw keys into commands, YAML, logs, or
transcripts. Prefer credential handles, Kubernetes
secretKeyRef, and runtime-only secret injection. Scan raw transcript exports withscripts/scan_transcript_secrets.pybefore sharing. - Use absolute paths. Derive repo root with
git rev-parse --show-toplevel.
Component References
Each component lives inside this skill so the stack has one canonical trigger. Load the component reference only when the selected target needs that slice.
| Concern | Load | Assets |
|---|---|---|
| Stage matrix and old driver notes | components/driver/reference.md |
None |
| MicroK8s cluster | components/cluster-microk8s/reference.md |
components/cluster-microk8s/scripts/, components/cluster-microk8s/runtimeclass-nvidia-runc.yaml |
| Azure AKS cluster | components/cluster-azure/reference.md |
components/cluster-azure/scripts/, components/cluster-azure/terraform/ |
| NIM Operator inference | components/inference-nim-operator/reference.md |
components/inference-nim-operator/scripts/, components/inference-nim-operator/nims/ |
| NVCF inference | components/inference-nvcf/reference.md |
components/inference-nvcf/scripts/ |
| Azure AI Foundry inference | components/inference-azure/reference.md |
components/inference-azure/scripts/ |
| MicroK8s OSMO | components/osmo-k8s/reference.md |
components/osmo-k8s/scripts/, upstream OSMO deploy scripts |
| Azure OSMO | components/osmo-azure/reference.md |
components/osmo-azure/scripts/, upstream OSMO deploy scripts plus Azure TF outputs |
| Azure access setup | components/azure-access/reference.md |
None |
| OSMO CLI and workflow operations | components/osmo-cli/reference.md |
components/osmo-cli/scripts/, components/osmo-cli/references/, components/osmo-cli/agents/, components/osmo-cli/tests/ |
| OpenClaw Azure device login | components/openclaw-azure-login/reference.md |
None |
OSMO CLI Support Files
The OSMO CLI component has second-level support files because its command and workflow surface is large. Load these directly only for the stated case.
| File | Read when |
|---|---|
components/osmo-cli/agents/workflow-expert.md |
Spawning a workflow-generation or workflow-failure subagent. |
components/osmo-cli/agents/logs-reader.md |
Spawning a log summarization subagent for OSMO workflow failures. |
components/osmo-cli/references/cli-commands.md |
Exact OSMO CLI flags, payloads, or command syntax are needed. |
components/osmo-cli/references/workflow-spec.md |
Workflow YAML schema, credentials, outputs, or provider fields are needed. |
components/osmo-cli/references/workflow-patterns.md |
Multi-task, data dependency, Jinja, serial, or parallel workflow design is needed. |
components/osmo-cli/references/advanced-patterns.md |
Checkpointing, retry/exit behavior, or node exclusion is needed. |
components/osmo-cli/tests/orchestrator-runtime-failure.md |
Validating or debugging the OSMO orchestration review pattern. |
Target Selection
Pick exactly one option per stage. Stage 2 follows stage 1.
- Kubernetes:
MicroK8sorAzure - OSMO:
MicroK8s OSMOwhen Kubernetes is MicroK8s,Azure OSMOwhen Kubernetes is Azure - Inference:
NIM Operator,NVCF,Azure AI Foundry, orNone - Workload: Video Data Augmentation, Defect Image Generation, NuRec Carline Adaptation, NRE, NCore, Asset Harvester, or custom workflow YAML
Reject invalid combinations before provisioning:
| Cluster | NIM Operator | NVCF | Azure AI Foundry |
|---|---|---|---|
| MicroK8s | yes | yes | no, Foundry requires Azure identities |
| Azure | yes | yes | yes |
For OpenClaw or any chat-only environment that cannot open a browser, read
components/openclaw-azure-login/reference.md before Azure prerequisites.
For any Azure target, read components/azure-access/reference.md before Azure
component preflights.
Setup Flow
- Confirm target choices and workload compute requirements.
- Load the selected component references.
- Resolve prerequisites up front, including API keys, Azure access, caller CIDR, GPU quota, storage class, and OSMO login requirements.
- Run
scripts/preflight.shfor every selected infrastructure component plus any OSMO CLI/workload preflight before provisioning; build the implementation plan from the results and stop on red preflight. - Deploy Kubernetes first. Nothing else starts until the cluster gate is green.
- Deploy OSMO and inference after Kubernetes. These can proceed in parallel once the cluster exists, but workload submission waits for both selected gates.
- Submit the workload only after OSMO, storage credentials, compute pool, and
selected inference endpoints are verified. For VDA, this includes
preflight_credentials.sh,pre_submit_guard.pywith resolved--setvalues, non-empty model-cache prefixes, and workflow-namespace endpoint smoke checks. - Monitor through completion. On failed workflow state, inspect events and logs
from
components/osmo-cli/reference.md; do not resubmit blindly.
Inference Discovery
Avoid over-deploying expensive endpoints.
- Scan the chosen workflow spec and default values for endpoint references:
*.osmo-nims.svc.cluster.local,api.nvcf.nvidia.com/*,*.inference.ai.azure.com, or*.cognitiveservices.azure.com. - Map each reference to the selected backend:
- NIM Operator: service name must match a directory under
components/inference-nim-operator/nims/. - NVCF: function URL or function ID must be supplied by the environment.
- Azure AI Foundry: endpoint name must be deployed through
components/inference-azure/scripts/install.sh.
- NIM Operator: service name must match a directory under
- If the workflow needs a capability the selected backend lacks, stop and report the mismatch. Do not silently substitute another model.
Verification Gates
Each stage has its own Verify section in the component reference. These gates are mandatory:
| Stage | Gate |
|---|---|
| Kubernetes | Cluster API reachable, nodes Ready, GPU capacity advertised for GPU paths, and CPU+NVCF paths have runtimeclass/nvidia mapped to runc. |
| Inference | Every endpoint referenced by the workload is reachable. NIM readiness uses /v1/health/ready; NVCF and Foundry still need task-specific authenticated checks. |
| OSMO | OSMO pods Ready, pool ONLINE, port-forward watchdogs alive, storage credentials configured, and verify-hello workflow COMPLETED. |
| Workload | Selected workload pre-submit guards pass before submit. osmo workflow query <id> reports COMPLETED and every task is green. Failed terminal states require events and logs before retry. |
Resilient Scaling
- Size the cluster from workload needs before provisioning. For Azure, check CPU
and GPU quota for the selected VM families before
terraform apply. - For NIM Operator, deploy only the NIMServices referenced by the workload. Each service pins GPU and model-cache storage for the lifetime of the cluster.
- Keep OSMO storage URL schemes aligned with the active backend. Local MicroK8s uses MinIO, Azure uses Blob-backed configuration.
- Treat Pending, Unknown, ImagePullBackOff, unbound PVCs, or 0 Ready replicas as layer failures. Investigate scheduling, storage, image credentials, and adjacent platform state before retrying the same command.
- For long deploys or workflow watches, provide heartbeat updates with current state, elapsed time, last useful observation, and next check.
Workload Routing
- Video Data Augmentation: use
skills/physical-ai-video-data-augmentation/SKILL.md. - Defect Image Generation: use
skills/physical-ai-defect-image-generation/SKILL.md. - NuRec carline adaptation: use
skills/carline-adaptation/SKILL.md. - NRE, NCore, and Asset Harvester live in the canonical NuRec catalog listed in
skills/INDEX.md. - Custom workload: submit the provided workflow YAML through OSMO after checking resource requests, image credentials, data credentials, and inference URLs.
Evaluation Prompts And Results
- Positive trigger: "Set up resilient Physical AI infrastructure for VDA on Azure AKS with NIM Operator." Expected: use this skill.
- Negative trigger: "Summarize recent OSMO workflow logs for this workflow ID." Expected: do not use this infrastructure setup skill unless the request also involves setup, scaling, validation, or recovery of the infrastructure stack.
Latest static review: 2026-05-26, description keywords match the expected routes above.
原文・著作権は Anthropic および各プラグイン作者に帰属します。日本語訳は Claude API による自動翻訳です。