Scene Hierarchy Designのロゴ

Scene Hierarchy Design

組織
SummerEngine
scene-hierarchy-design

Structure scenes by access pattern: asset vs live hierarchies, wrapper nodes, sub-scenes, path-agnostic code.

概要

公開者SummerEngine
リポジトリsummer
スキル名scene-hierarchy-design
スター
91
フォーク
8
同梱ファイル
1
ライセンスMIT
リンク
  • Markdown形式の指示

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

  • どのLLMでも利用可能

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

  • 1個の同梱ファイル

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

  • オープンソース

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

インストール

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

1

TypingMindにインストール

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

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

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

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

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

TypingMindで使用

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

関連するリクエストがあるとすぐに、モデルが自動的にScene Hierarchy Designを読み込みます。

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

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

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

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

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

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

スキルの指示

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

Scene Hierarchy Design for Summer Engine (Data-Oriented Principles)

Outcome

Scenes in Summer Engine that are organized by access pattern, not by accident: clear separation between reusable asset scenes (.tscn prefabs) and the live node tree, wrapper grouping where whole subtrees are operated on together, flat siblings where type-wide queries dominate, and gameplay logic that does not depend on deep fragile node paths.

When to Use

  • Structuring a new scene (level, character, prop cluster, UI screen) from scratch.
  • Reorganizing a scene that has grown ad hoc (long chains, duplicate setups, hard-to-delete clusters).
  • Deciding whether a setup belongs inline or as a separate sub-scene.
  • Reviewing whether existing scenes match the dominant operations the game performs on them (spawn/despawn clusters, iterate all of a type, move single nodes).

Do not use this for shader/material work, asset import mechanics, or gameplay tuning — it is purely about hierarchy shape.

Core Principle (translated)

Sander Mertens' ECS article evaluates hierarchies on two axes and both translate directly:

  1. Usability: two hierarchy kinds must compose. Asset hierarchies (inheritance, variations, property overrides → .tscn sub-scenes and scene inheritance) and scene hierarchies (live parent-child relations → the node tree). A scene that repeatedly rebuilds the same inline cluster is missing its asset hierarchy; an asset scene nobody instantiates is dead weight.
  2. Performance: match structure to dominant access patterns. Group nodes stored/operated together under one parent (subtree operations become one operation); keep nodes queried independently as flat siblings. There is no universally optimal depth — analyze usage before picking one.
  3. Hierarchy-agnostic logic. The article's hybrid design keeps application code independent of storage; the Summer translation is: scripts and agents should not hardcode deep paths. Use groups, signals, and exported NodePath references instead of long ancestor chains.

Summer Engine Integration

Scene hierarchy features from the article map onto Summer MCP tools as follows:

Feature (article)Summer Engine tool
Instantiate assetssummer_instantiate_scene
Recursively despawnsummer_remove_node on the wrapper parent (removes the subtree)
Reparent childrensummer_remove_node + summer_add_node/summer_instantiate_scene under the new parent
Iterate the live hierarchysummer_get_scene_tree (always read before mutating)
Lookup by namedescriptive, unique node names resolved from summer_get_scene_tree

Recommended scene shape — group by operation, name by role:

World (Node3D)                  # scene root
├── Camera3D                    # unique to this scene → inline
├── DirectionalLight3D          # unique → inline
├── Level (Node3D)              # wrapper: geometry operated as one subtree
├── Props (Node3D)              # wrapper: spawn/despawn clusters together
│   ├── Crate_01 (instance of res://scenes/props/crate.tscn)
│   └── Barrel_01 (instance)
├── Enemies (Node3D)            # wrapper: recursive clear of all enemies
│   └── Grunt_01 (instance of res://scenes/enemies/grunt.tscn)
└── Player (instance of res://scenes/player.tscn)

Rules of thumb:

  • Wrapper node per operation boundary. If you ever need to "remove all enemies", "hide all props", or "rebuild the level", they share one parent; the operation becomes a single node op.
  • Sub-scene per reusable setup. Same cluster appearing twice or more → extract to its own .tscn and instantiate. One-offs (main camera, a level-specific light) stay inline.
  • Flat over deep. Every extra level of nesting adds path length and fragility. Prefer named sibling containers over long chains.
  • Unique descriptive names. The engine auto-renames duplicates (Node, Node2); that breaks name lookup. Name by role and index (Crate_01).
  • Never mix 2D under 3D (or vice versa) in one hierarchy.

Agent Procedure

Follow the canonical scene loop from the Summer MCP reference: route → orient → read rules → resolve scenePath → mutate → verify.

  1. Orient. summer_call {"op":"docs.plan"} to route the goal; summer_get_project_context; summer_call {"op":"summer_get_agent_playbook"}.
  2. Read before writing. summer_get_scene_tree on the exact res://...tscn. Never mutate blind, and never edit .tscn text while the engine is running — use the MCP tools.
  3. Pick the access pattern. For each planned cluster decide: operated as a subtree (→ wrapper parent), queried by type across the scene (→ flat siblings + group), or unique (→ inline under root container).
  4. Build asset hierarchies first. For reusable setups create the sub-scene (summer_create_scene / build inline then summer_save_scene(scenePath="res://main.tscn", path="res://scenes/<name>.tscn")), then bring them in with summer_instantiate_scene(scenePath="res://main.tscn", parent="./<Wrapper>", scene="res://scenes/<name>.tscn", name="<Role>_01").
  5. Add inline nodes with summer_add_node(parent="./<Wrapper>", type="...", name="...", scenePath="res://main.tscn"). Parent paths are relative with the ./ prefix (./, ./World/Props); never /World or bare World.
  6. Keep logic path-agnostic. When a script must reach another node, add it to a group or export a NodePath/signal connection (summer_connect_signal) rather than hardcoding ./World/Enemies/Grunt_01/Weapon.
  7. Every mutation names its target. Pass the exact scenePath to every add/set/remove/instantiate call. Dedicated mutation tools append one final save; use summer_save_scene only for save-as or an explicit flush.
  8. Verify. summer_get_script_errors, then summer_get_scene_tree again to confirm the intended shape; summer_screenshot (editor viewport) for visual confirmation; summer_play → summer_get_debugger_errors → summer_stop only when runtime behaviour matters.

Failure Modes

  • Deep fragile paths in scripts. Hardcoded ancestor chains break on any reorganization; this is the direct analogue of the article's warning against logic coupled to hierarchy storage. Use groups/signals/exported paths.
  • Inline duplication instead of sub-scenes. The same 5-node cluster rebuilt in three levels → edits must be made three times, and despawn/iteration must enumerate each copy. Extract the asset hierarchy.
  • Over-grouping. Wrapping every node in its own container adds depth without enabling any operation. Group only where a real subtree operation exists.
  • Duplicate/unnamed nodes. Auto-renamed Node2 nodes break lookup-by-name. Rename immediately after adding.
  • Wrong parent path. ./NonExistent fails; ensure the parent exists before adding children (read the tree first).
  • Copying a scene as a template without auditing transforms. Carried-over instances keep world-space offsets baked for the source level; re-zero or drop transform overrides per instance.
  • Direct .tscn edits while running. They get overwritten when the editor saves; always go through MCP scene tools.

Verification

  1. summer_get_scene_tree shows the intended wrapper structure with unique descriptive names and no auto-renamed nodes.
  2. Each repeated setup exists once as a .tscn and appears elsewhere only as instances.
  3. Deleting a wrapper parent (summer_remove_node) removes exactly its subtree — the recursive-despawn feature works.
  4. No script references a path deeper than one or two segments; group/signal/NodePath used instead.
  5. summer_get_script_errors and (if played) summer_get_debugger_errors are clean; summer_screenshot matches the intended layout.

From a shell

No Summer MCP tools in this session? Run each one as a command; when summer --version is missing or below 4.0, use npx -y summer-engine@latest in place of summer. Fields are flags in kebab-case (--scene-path res://main.tscn) or one --input '<json>', and summer ops describe <op> prints the exact input. The summer-cli skill has the rest.

In this skillCommand
docs.plansummer docs plan
summer_add_nodesummer engine add-node
summer_connect_signalsummer engine connect-signal
summer_create_scenesummer engine create-scene
summer_get_debugger_errorssummer engine get-debugger-errors
summer_get_project_contextsummer engine get-project-context
summer_get_scene_treesummer engine get-scene-tree
summer_get_script_errorssummer engine get-script-errors
summer_instantiate_scenesummer engine instantiate-scene
summer_playsummer engine play
summer_remove_nodesummer engine remove-node
summer_save_scenesummer engine save-scene
summer_screenshotsummer engine screenshot
summer_stopsummer engine stop
summer_get_agent_playbooksummer tool get-agent-playbook

同梱ファイル

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

よくある質問

AIスキル「Scene Hierarchy Design」では何ができますか?

Structure scenes by access pattern: asset vs live hierarchies, wrapper nodes, sub-scenes, path-agnostic code.

TypingMindでScene Hierarchy Designを使うメリットは何ですか?

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

TypingMindにScene Hierarchy Designをインストールするにはどうすればよいですか?

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

Scene Hierarchy Designを使えるAIモデルはどれですか?

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

Scene Hierarchy Designで使えるAIモデルの数に制限はありますか?

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

AIスキル「Scene Hierarchy Design」は無料ですか?

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

AIスキルとは何ですか?

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

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

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

すべて見る

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

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