Cuda To Xpu Migrationのロゴ

Cuda To Xpu Migration

組織
intel
cuda-to-xpu-migration

Create a CUDA-to-XPU migration assessment for an existing AI repo. Identify CUDA-specific assumptions, route to the right XPU skills, produce a migration report. Use when the user has a CUDA repo, notebook, Dockerfile, launch script, HF / vLLM / SGLang workload, or Triton kernel and asks to migrate it to Intel Arc / Arc Pro / Battlemage / XPU — including "convert this to XPU" / "move it to XPU" and the bare "migrate this repo" request where scope is not yet set. A request that says "port" routes to xpu-port. Plans and routes only. Not for executing an already-scoped rewrite (use xpu-port), running migrated code, or measuring it.

概要

公開者intel
リポジトリskills
スキル名cuda-to-xpu-migration
スター
31
フォーク
14
同梱ファイル
2
ライセンスApache-2.0
リンク
  • Markdown形式の指示

    モデルが必要に応じて読み込むSKILL.mdファイルです。関連するリクエストがあったときだけトークンを消費します。

  • どのLLMでも利用可能

    AIスキルはプロバイダー固有のコードではなく、通常のMarkdownなので、GPT、Claude、Gemini、Grok、ローカルモデルで利用できます。

  • 2個の同梱ファイル

    モデルが作業中に読み取れるスクリプト、テンプレート、参考資料です。ファイルは読み取り専用で、実行されることはありません。

  • オープンソース

    intelがGitHubで公開しています。インストールする前にソースを確認してください。

インストール

AIスキル「Cuda To Xpu Migration」をTypingMindにインストールすれば、どのLLMでも利用できます。SKILL.mdを読み取れる別のAIエージェントに追加することもできます。

1

TypingMindにインストール

TypingMindはGitHubフォルダから直接スキルをインストールします。SKILL.mdを読み取り、リソースファイルをまとめてローカルに保存します。

  1. アプリを開き、「プラグイン」→「スキル」に移動します。
  2. 「GitHubからインストール」を選択します。
  3. 以下のスキルフォルダのURLを貼り付けて確定します。
    https://github.com/intel/skills/tree/main/skills/cuda-to-xpu-migration
  4. スキルを利用したいチャットごとに、そのスキルを有効にしてください。
「プラグイン」→「スキル」→「スキルを追加」→「GitHubのURLから」を選択し、フォルダのURLを貼り付けて「続行」を押します。
2

別のAIエージェントにインストール

Agent Skills形式を読み取れるAIエージェントなら、このスキルを利用できます。フォルダをそのAIエージェントのスキルディレクトリにコピーしてください。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/intel/skills.git /tmp/skills
mkdir -p .claude/skills
cp -r /tmp/skills/skills/cuda-to-xpu-migration .claude/skills/cuda-to-xpu-migration
コピー後、新しいスキルを読み込むためにClaude Codeを再起動してください。

TypingMindで使用

TypingMindのチャットでCuda To Xpu Migrationを有効にするだけで、あとはモデルが対応します。名前と説明がシステムプロンプトに含まれ、関連するリクエストがあると、モデルが指示の全文を自動で読み込みます。手動で呼び出す必要はなく、実際に使用されるまでトークンを消費しません。

関連するリクエストがあるとすぐに、モデルが自動的にCuda To Xpu Migrationを読み込みます。

どのAIモデルでも利用可能

AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、Cuda To Xpu Migrationは作成時に想定されたモデルに縛られません。TypingMindに一度インストールすれば、ご自身のAPIキーを使って、GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama、またはご自身で実行するローカルモデルで利用できます。

  • 必要なときだけ読み込み

    システムプロンプトには名前と説明だけが含まれます。関連するリクエストが初めてあったときに指示を取得するため、スキルを使わない間は指示の読み込みにトークンを消費しません。

  • チャットの途中でモデルを切り替え

    スキルはコードではなく指示なので、モデルを切り替えてもそのまま使えます。次のモデルも同じSKILL.mdを読み込みます。

スキルの指示

モデルが読み込むSKILL.mdの内容です。スキルはモデルが従う指示なので、インストールする前に確認してください。

cuda-to-xpu-migration

Create a migration assessment for CUDA-oriented repos that want an Intel XPU path.

Scope

This skill is for assessment and planning only.

  • Identify CUDA-specific assumptions and likely migration surfaces.
  • Reuse existing skills for code translation, runtime setup, serving, profiling, and sizing.
  • Produce a clean migration report with recommended edits, blockers, and next steps.
  • Do not execute or validate migrated code.
  • Do not duplicate detailed commands or framework runbooks that are already covered by other skills.

Always assess; route forward once

This skill assesses the workflow verbs — "assess", "migrate", "convert", "move" — with the same read-only pass: inventory, classify, report. A request that says "port" (or otherwise names the rewrite explicitly) belongs to xpu-port, not here; route it there. For the workflow verbs, do not bounce the request away before the report exists: a mis-routed execution request costs one cheap read-only assessment, while the reverse mis-route would rewrite a user's repo unasked.

The report's Next steps (with the "Non-namespace CUDA surfaces → Route" table) is the single onward-routing authority. It names the executor for each surface — xpu-port for portable Python, xpu-deploy-plan for API-first / serving repos, container and runtime skills per tier. Routing flows one way, assess → execute; nothing here routes backward.

Use with

  • xpu-discover for an XPU environment / driver preflight check before recommending a migration target.
  • xpu-runtime-preflight for a read-only go/no-go check of host/container XPU readiness (drivers, /dev/dri, permissions, runtime, and essentials) before any XPU workload.
  • torch-xpu-run for PyTorch / Transformers CUDA-to-XPU code translation guidance.
  • xpu-container-run for container runtime setup on Intel GPU.
  • vllm-xpu-run for vLLM launch and runtime guidance.
  • sglang-xpu-run for SGLang launch and runtime guidance.
  • model-can-it-fit and model-config-recommend for fit and config decisions.
  • xpu-deploy-plan for a coordinated end-to-end serving plan (preflight → fit → config → launch → smoke test) once the assessment routes an API-first / serving-stack repo to a local XPU endpoint.

Migration flow

  1. Inventory

    • If the request is a git URL (not a local path), shallow-clone it to a stated scratch location first (e.g. git clone --depth 1 <url> /tmp/<repo>-assess) and assess that path. State the clone target before scanning — do not assess a URL from memory.
    • If the user's request does not include a repo path, search the local workspace for the relevant scripts or repo (e.g. find ~/workspace -name "*.sh" -path "*vllm*"). State which path you are assessing before running the scan — do not silently assume a location.
    • Run scripts/inventory.sh from the target repo root to surface CUDA/NVIDIA references and common launch/runtime surfaces.
    • Group findings by area: framework code, runtime/container, serving stack, Triton kernels, and CUDA-native dependencies.
    • Notebooks: inventory.sh greps .ipynb files as text, so CUDA references in notebook cells are surfaced. Notebook code cells are not directly rewritable: for a notebook-heavy repo, flag that code cells need extraction to .py (or hand-porting) before the port executes, and note it under "Needs version-aware review".
  2. Classify

    • Safe translation candidates: portable PyTorch / Transformers code.
    • Runtime changes: container flags, environment variables, launch scripts.
    • Version-sensitive changes: vLLM / SGLang internals and plugin code.
    • Likely blockers: CUDA extensions, CuPy, NCCL, TensorRT, flash-attn, bitsandbytes, cuBLAS / CUTLASS / cuTENSOR / cuSPARSE / cuDNN consumers, custom .cu / .cuh code.
    • Cloud-API / provider references (not CUDA): many "NVIDIA" hits are HTTP-client calls, not local GPU code — NVIDIA NIM (integrate.api.nvidia.com, langchain-nvidia-ai-endpoints, build.nvidia.com), or unrelated cloud services (ElevenLabs, OpenAI). These do not need a CUDA port. Classify them as: provider swap (retarget a local vLLM-XPU / SGLang-XPU OpenAI-compatible endpoint and change the api_base / model name — no Python rewrite) or unaffected (GPU-agnostic cloud dependency, e.g. a TTS API). Do not count these toward the CUDA migration surface — the pdf-to-podcast blueprint had ~170 grep hits at the time of assessment (upstream is unpinned, so the exact count drifts) and zero actual CUDA code.
  3. Route

    • For XPU environment / driver preflight, use xpu-discover.
    • For PyTorch / Transformers code translation, use torch-xpu-run.
    • For container changes, use xpu-container-run.
    • For vLLM / SGLang serving paths, use vllm-xpu-run or sglang-xpu-run.
    • For deployment and capacity planning, use model-can-it-fit, and model-config-recommend.
    • For non-namespace CUDA constructs, route per the per-construct guidance in the "Non-namespace CUDA surfaces" section of templates/migration_report.md: torch.compile and pin_memory → xpu-port (execution) / torch-xpu-run (reference); ProfilerActivity.CUDA → torch-xpu-profile; set_float32_matmul_precision / TF32 toggles → delete (no-op on XPU).
  4. Report

    • When ready to write the final assessment, read templates/migration_report.md and fill it in.
    • The verdict line, copied verbatim from the template, must appear as the first line of your final message — Migration result: <COMPLETE | PARTIAL | BLOCKED>. Keep the literal prefix Migration result: intact — do not abbreviate it to Result:, and do not fold it into a heading (e.g. ## Migration Assessment followed by **Result: PARTIAL**). If you save the report to a file, do that step first, then make the verdict line the opening of the closing message — do not lead with the report and trail off in a paraphrased summary that drops the line. It is the headline of the assessment and the marker a reader uses to confirm an assessment — not a refusal — was produced.
    • Summarize what appears directly portable, what needs version-aware review, and what is blocked on CUDA-native components.
    • Recommend the next skill(s) to use for each category.

Migration tiers

TierSurfaceAction
1PyTorch / HF / Diffusers PythonRoute to torch-xpu-run for code translation guidance.
2Docker / shell / benchmark scriptsRoute to xpu-container-run for runtime/container guidance.
3vLLM / SGLang launch scriptsRoute to vllm-xpu-run / sglang-xpu-run.
4Triton kernelsCheck whether equivalent kernels already exist in the intel/intel-xpu-backend-for-triton repo. If a matching kernel exists, plan to reuse it; otherwise flag for XPU review and correctness/perf follow-up.
5CUDA-native libraries and custom opsMark as blockers or redesign candidates; do not claim mechanical migration.

CUDA-native blockers and routes

ComponentWhy it blocksRoute
CUDA C++ / .cu custom opCUDA kernels do not run on XPU directly.Replace with torch native ops, Triton XPU, SYCL/oneAPI extension, or fallback path.
CuPyCUDA array runtime.Replace with torch, NumPy CPU fallback, dpctl/SYCL path, or isolate.
NCCLNVIDIA collective library.Use XPU distributed guidance from the appropriate runtime skill.
TensorRTNVIDIA inference runtime.Route to vLLM-XPU, SGLang-XPU, OpenVINO, or PyTorch XPU depending on target.
flash-attnCUDA-specific optimized attention package.Use runtime-native attention backend or fallback recommended by the runtime skill.
bitsandbytesCUDA-centric quantization/runtime kernels.Route to an XPU-supported quantized path or alternative checkpoint/runtime.
cuBLAS / CUTLASS / cuTENSOR / cuSPARSE / cuDNNNVIDIA-only compute libraries (GEMM, attention building blocks, sparse ops, DNN primitives).Replace with torch native ops on XPU (oneDNN-backed), oneMKL, or rewrite via Triton XPU / SYCL.
CUDA GraphsCUDA execution feature.Disable, replace, or branch only if the current XPU runtime supports the path.

Files in this skill

  • scripts/inventory.sh — read-only CUDA/NVIDIA inventory scan; run from the target repo root.
  • templates/migration_report.md — final report template; load only when writing the migration report.

What this skill does NOT cover

  • Executing or validating migrated code.
  • Repeating detailed code-translation tables already covered by torch-xpu-run.
  • Repeating detailed container command guidance already covered by xpu-container-run.
  • Claiming feature parity for NVIDIA-only libraries.

同梱ファイル

スキルが読み込まれている間、モデルは必要に応じてこれらを読み取ります。読み取り可能なファイルとして提供され、実行されることはありません。

よくある質問

AIスキル「Cuda To Xpu Migration」では何ができますか?

Create a CUDA-to-XPU migration assessment for an existing AI repo. Identify CUDA-specific assumptions, route to the right XPU skills, produce a migration report. Use when the user has a CUDA repo, notebook, Dockerfile, launch script, HF / vLLM / SGLang workload, or Triton kernel and asks to migrate it to Intel Arc / Arc Pro / Battlemage / XPU — including "convert this to XPU" / "move it to XPU" and the bare "migrate this repo" request where scope is not yet set. A request that says "port" routes to xpu-port. Plans and routes only. Not for executing an already-scoped rewrite (use xpu-port),...

TypingMindでCuda To Xpu Migrationを使うメリットは何ですか?

一度インストールすれば、どのモデルでも使えるからです。Cuda To Xpu Migrationはプロバイダー固有のコードではなく、通常のMarkdownで記述されているため、同じスキルをGPT-5、Claude、Gemini、Grok、ローカルモデルで利用できます。チャットの途中でモデルを切り替えても、そのまま使い続けられます。TypingMindは自分のAPIキーで動作するため、シート単位のサブスクリプションではなく、プロバイダーに直接料金を支払います。スキルとチャットは自分のストレージに保持されます。

TypingMindにCuda To Xpu Migrationをインストールするにはどうすればよいですか?

TypingMindで「プラグイン」→「スキル」→「GitHubからインストール」を開き、https://github.com/intel/skills/tree/main/skills/cuda-to-xpu-migrationを貼り付けてください。TypingMindがSKILL.mdを読み込み、関連ファイルをまとめて、チャットごとに有効にできるスキルとしてインストールします。

Cuda To Xpu Migrationを使えるAIモデルはどれですか?

TypingMindに接続したどのモデルでも利用できます。AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、GPT、Claude、Gemini、Grok、ローカルモデルのいずれも、リクエストの内容がこのスキルの用途に合ったときに、このスキルを読み込めます。

Cuda To Xpu Migrationで使えるAIモデルの数に制限はありますか?

数に制限はありません。スキルに対応したモデルであれば、GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llamaなど、どのモデルでもCuda To Xpu Migrationを利用できます。すべてTypingMind上で、自分のAPIキーを使って利用できます。

AIスキル「Cuda To Xpu Migration」は無料ですか?

はい。intelがApache-2.0ライセンスのもとでGitHubに公開しています。ご利用のAIプロバイダーに支払うのは、使用したトークンの料金だけです。

AIスキルとは何ですか?

AIスキルは、特定のタスクの実行方法をAIモデルに教える、再利用可能な指示のセットです。オープンなAgent Skills形式に従い、名前と説明を含むSKILL.mdファイルに加え、モデルが必要とするスクリプト、テンプレート、参照ファイルで構成されます。モデルはリクエストがスキルに合致したときだけ指示を読み込むため、インストール済みのスキルも、使うまでは費用がかかりません。

AIスキルは、プラグインやMCPサーバーとどう違いますか?

プラグインやMCPサーバーは、モデルが呼び出せる新しいツールを提供します。ツールとは、どこかで実行され、結果を返すコードです。一方、AIスキルは、タスクへの取り組み方、従うべき手順、望ましい出力の例といった知識や進め方をモデルに伝えます。スキルは通常のMarkdownで記述されているため、サーバー、APIキー、実行環境は不要で、どのモデルでも利用できます。

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇