/batch
Unified batch and async-job orchestration. 统一的批量与异步任务编排。
$ npx -y skills add Besty0728/Unity-Skills --skill batch --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
- Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
- You can call itInvoke it directly when you want it.
- Slash command
/batch
Context preview
The summary Claude sees to decide when to auto-load this skill.
Unified batch and async-job orchestration. 统一的批量与异步任务编排。
SKILL.md
batch.SKILL.mdname: unity-batch
description: Unified batch and async-job orchestration. 统一的批量与异步任务编排。
Triggers
- Operating on many objects at once
- Running or polling long async jobs
- Preview-then-commit bulk edits
- 一次性操作大量对象、运行或轮询长时异步任务、先预览后提交的批量编辑
Unity Batch Skills
Batch workflow orchestration for query, preview, execution, reports, and async jobs.
Operating Mode
本模块共 22 个 skill,按 Operation 区分为两类:
- **18 个 SemiAuto**(query / preview / report / job 查询类):`batch_query_gameobjects` / `batch_query_components` / `batch_query_assets` / `batch_preview_rename` / `batch_preview_set_property` / `batch_preview_replace_material` / `batch_report_get` / `batch_report_list` / `job_status` / `job_progress` / `job_logs` / `job_list` / `batch_fix_missing_scripts` / `batch_standardize_naming` / `batch_set_render_layer` / `batch_replace_material` / `batch_validate_scene_objects` / `batch_cleanup_temp_objects`。Approval 模式下可直接执行。
- **4 个 FullAuto**(Execute 类,C# 未标 `Mode` 走默认 `SkillMode.FullAuto`):`batch_execute` / `job_wait` / `job_cancel` / `batch_retry_failed`。Approval 模式下首次调用返 `MODE_RESTRICTED`,走 grant 协议。
- Auto / Bypass:两类都直接执行。**不含 NeverInSemi 高危 skill**(无 Delete/MayEnterPlayMode/MayTriggerReload 标记)。
> 注意:`batch_execute(confirmToken)` 本身放行,但它执行的 preview 内容可能包括对场景对象的删除/改属性等高影响动作 —— 请确保 `batch_preview_*` 返回的 sample/risk 字段已审阅。confirmToken 一次性消费、过期需重新 preview。
**DO NOT** (common hallucinations):
- Always call a `batch_preview_*` skill first — `batch_execute` requires a `confirmToken` from a preview, it cannot be called directly
- `batch_run` does not exist → use `batch_execute(confirmToken)`
- `job_poll` / `job_result` do not exist → use `job_status` to check and retrieve async job results
- `batch_delete` / `batch_move` do not exist → use `asset` module for asset-level operations
**Routing**:
- For asset-level bulk operations (move, copy, delete) → `asset` module
- For workflow session/task undo tracking → `workflow` module
- For scene object validation → `batch_validate_scene_objects` (this module)
- For async job polling → `job_status` / `job_wait` (this module)
Skills
batch_query_gameobjects
Query GameObjects with unified batch filters. `queryJson` supports `name/path/instanceId/tag/layer/active/componentType/sceneName/parentPath/prefabSource/includeInactive/limit`.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `queryJson` | string | No | null | JSON query filter envelope | | `sampleLimit` | int | No | 20 | Max sample objects returned |
batch_query_components
Query components with unified batch filters. Optional `componentType` narrows the result.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `queryJson` | string | No | null | JSON query filter envelope | | `componentType` | string | No | null | Optional component type constraint | | `sampleLimit` | int | No | 20 | Max sample objects returned |
batch_query_assets
Query project assets by type, path pattern, and labels. Read-only.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `searchFilter` | string | No | null | Raw Unity AssetDatabase filter string | | `folder` | string | No | "Assets" | Search root folder | | `typeFilter` | string | No | null | Asset type (prefix `t:` optional, e.g. `Texture2D`) | | `namePattern` | string | No | null | Case-insensitive regex for filename | | `labelFilter` | string | No | null | Asset label (prefix `l:` optional) | | `maxResults` | int | No | 200 | Max results returned |
batch_preview_rename
Preview batch renaming. `mode` supports `prefix` / `suffix` / `replace` / `regex_replace`.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `queryJson` | string | No | null | JSON query filter envelope | | `mode` | string | No | "prefix" | Rename mode | | `prefix` | string | No | null | Prefix to add | | `suffix` | string | No | null | Suffix to add | | `search` | string | No | null | Plain text search term | | `replacement` | string | No | null | Plain text replacement | | `regexPattern` | string | No | null | Regex search pattern | | `regexReplacement` | string | No | null | Regex replacement text | | `sampleLimit` | int | No | DefaultSampleLimit | Max preview items |
batch_preview_set_property
Preview setting a component property or field across queried targets.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `queryJson` | string | No | null | JSON query filter envelope | | `componentType` | string | No | null | Target component type | | `propertyName` | string | No | null | Property or field name | | `value` | string | No | null | Literal value | | `referencePath` | string | No | null | Scene reference path | | `referenceName` | string | No | null | Scene reference object name | | `assetPath` | string | No | null | Asset reference path | | `sampleLimit` | int | No | DefaultSampleLimit | Max preview items |
batch_preview_replace_material
Preview replacing Renderer materials across queried targets.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `queryJson` | string | No | null | JSON query filter envelope | | `materialPath` | string | No | null | Replacement material asset path | | `sampleLimit` | int | No | DefaultSampleLimit | Max preview items |
batch_execute
Execute a previously previewed batch operation by `confirmToken`. Large operations return a `jobId`.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `confirmToken` | string | Yes | - | Preview confirmation token | | `runAsync` | bool | No | true | Run as async job | | `chunkSize` | int | No | 100 | Batch execution chunk size | | `progressGranularity`
Read more
name: unity-batch description: Unified batch and async-job orchestration. 统一的批量与异步任务编排。
Triggers
- Operating on many objects at once
- Running or polling long async jobs
- Preview-then-commit bulk edits
- 一次性操作大量对象、运行或轮询长时异步任务、先预览后提交的批量编辑
Unity Batch Skills
Batch workflow orchestration for query, preview, execution, reports, and async jobs.
Operating Mode
本模块共 22 个 skill,按 Operation 区分为两类:
- **18 个 SemiAuto**(query / preview / report / job 查询类):`batch_query_gameobjects` / `batch_query_components` / `batch_query_assets` / `batch_preview_rename` / `batch_preview_set_property` / `batch_preview_replace_material` / `batch_report_get` / `batch_report_list` / `job_status` / `job_progress` / `job_logs` / `job_list` / `batch_fix_missing_scripts` / `batch_standardize_naming` / `batch_set_render_layer` / `batch_replace_material` / `batch_validate_scene_objects` / `batch_cleanup_temp_objects`。Approval 模式下可直接执行。
- **4 个 FullAuto**(Execute 类,C# 未标 `Mode` 走默认 `SkillMode.FullAuto`):`batch_execute` / `job_wait` / `job_cancel` / `batch_retry_failed`。Approval 模式下首次调用返 `MODE_RESTRICTED`,走 grant 协议。
- Auto / Bypass:两类都直接执行。**不含 NeverInSemi 高危 skill**(无 Delete/MayEnterPlayMode/MayTriggerReload 标记)。
> 注意:`batch_execute(confirmToken)` 本身放行,但它执行的 preview 内容可能包括对场景对象的删除/改属性等高影响动作 —— 请确保 `batch_preview_*` 返回的 sample/risk 字段已审阅。confirmToken 一次性消费、过期需重新 preview。
**DO NOT** (common hallucinations):
- Always call a `batch_preview_*` skill first — `batch_execute` requires a `confirmToken` from a preview, it cannot be called directly
- `batch_run` does not exist → use `batch_execute(confirmToken)`
- `job_poll` / `job_result` do not exist → use `job_status` to check and retrieve async job results
- `batch_delete` / `batch_move` do not exist → use `asset` module for asset-level operations
**Routing**:
- For asset-level bulk operations (move, copy, delete) → `asset` module
- For workflow session/task undo tracking → `workflow` module
- For scene object validation → `batch_validate_scene_objects` (this module)
- For async job polling → `job_status` / `job_wait` (this module)
Skills
batch_query_gameobjects
Query GameObjects with unified batch filters. `queryJson` supports `name/path/instanceId/tag/layer/active/componentType/sceneName/parentPath/prefabSource/includeInactive/limit`.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `queryJson` | string | No | null | JSON query filter envelope | | `sampleLimit` | int | No | 20 | Max sample objects returned |
batch_query_components
Query components with unified batch filters. Optional `componentType` narrows the result.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `queryJson` | string | No | null | JSON query filter envelope | | `componentType` | string | No | null | Optional component type constraint | | `sampleLimit` | int | No | 20 | Max sample objects returned |
batch_query_assets
Query project assets by type, path pattern, and labels. Read-only.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `searchFilter` | string | No | null | Raw Unity AssetDatabase filter string | | `folder` | string | No | "Assets" | Search root folder | | `typeFilter` | string | No | null | Asset type (prefix `t:` optional, e.g. `Texture2D`) | | `namePattern` | string | No | null | Case-insensitive regex for filename | | `labelFilter` | string | No | null | Asset label (prefix `l:` optional) | | `maxResults` | int | No | 200 | Max results returned |
batch_preview_rename
Preview batch renaming. `mode` supports `prefix` / `suffix` / `replace` / `regex_replace`.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `queryJson` | string | No | null | JSON query filter envelope | | `mode` | string | No | "prefix" | Rename mode | | `prefix` | string | No | null | Prefix to add | | `suffix` | string | No | null | Suffix to add | | `search` | string | No | null | Plain text search term | | `replacement` | string | No | null | Plain text replacement | | `regexPattern` | string | No | null | Regex search pattern | | `regexReplacement` | string | No | null | Regex replacement text | | `sampleLimit` | int | No | DefaultSampleLimit | Max preview items |
batch_preview_set_property
Preview setting a component property or field across queried targets.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `queryJson` | string | No | null | JSON query filter envelope | | `componentType` | string | No | null | Target component type | | `propertyName` | string | No | null | Property or field name | | `value` | string | No | null | Literal value | | `referencePath` | string | No | null | Scene reference path | | `referenceName` | string | No | null | Scene reference object name | | `assetPath` | string | No | null | Asset reference path | | `sampleLimit` | int | No | DefaultSampleLimit | Max preview items |
batch_preview_replace_material
Preview replacing Renderer materials across queried targets.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `queryJson` | string | No | null | JSON query filter envelope | | `materialPath` | string | No | null | Replacement material asset path | | `sampleLimit` | int | No | DefaultSampleLimit | Max preview items |
batch_execute
Execute a previously previewed batch operation by `confirmToken`. Large operations return a `jobId`.
| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | `confirmToken` | string | Yes | - | Preview confirmation token | | `runAsync` | bool | No | true | Run as async job | | `chunkSize` | int | No | 100 | Batch execution chunk size | | `progressGranularity`
REST API-based AI-driven Unity Editor Automation Engine Let AI control Unity scenes directly through Skills 🎉 We are now indexed by DeepWiki! Got questions? Check out the AI-generated docs → The current official maintenance baseline is Unity 2022.3+.
Other skills on unity-skills.
- /addressables-design
Source-anchored design rules for Unity Addressables 1.22.3/2.9.1. 为 Unity Addressables 1.22.3/2.9.1 提供源码锚定的设计规则。
Open skill - /adr
Record Unity architecture decisions (ADR) with rationale. 记录 Unity 架构决策(ADR)与理由。
Open skill - /animator
Edit Unity Animator Controllers and drive runtime parameters. 编辑 Unity Animator Controller 并驱动运行时参数。
Open skill - /architecture
Advise on Unity gameplay and system architecture. 为 Unity 游戏与系统架构提供建议。
Open skill - /asmdef
Advise on Unity assembly definitions (asmdef). 为 Unity 程序集定义(asmdef)提供建议。
Open skill - /asset
Manage Unity AssetDatabase operations. 管理 Unity AssetDatabase 操作。
Open skill

