Unity Semantic Bridge
FreeNot checkedAgent to help LLMs understand and interact with Unity scenes.
About
Agent to help LLMs understand and interact with Unity scenes.
README
A Unity MCP Bridge built for agents working alongside you in a live Editor session — not just querying a static project. Token-efficient tools give your agent visibility into what changed in the scene while you were both working in it.

Features
- Optimized scene heirarchy query and gameobject inspection tools with workflow hints for agents - more token efficient than official Unity CLI tool
- In Editor connection status and reconnect. Not tied to Unity Licensing - Runs 100% local. No need to reauthenticate when token expires
- Dedicated tools for agent to see human actions and changes
- In Editor MCP log so you can see what tools are called
- Dedicated Lighting tools for URP projects
Prerequesites
- Unity 2022.3 LTS up to Unity 6.3
- uses
UnityEditor.ObjectChangeEvents.changesPublishedavailable in 2022.3 LTS and later - versions of Unity newer than 6.3 use change
InstanceIdsforEntityIds- not tested for compatibility yet
- uses
- uv (https://docs.astral.sh/uv/getting-started/installation/)
Optional
- API key for LLM with strong vision capabiltiies - lighting subagent can be powered by a separate LLM (ideally with vision-in-the-loop like Fable 5 or Kimi K3); see
/core/llm_provider.py. Tools are still available to your main/orchestrator agent even without setting up the subagent. Previously used mcp sampling but this was deprecated.
Installation
- Clone this project.
- Add the Unity package in
/com.gamenami.unity-semantic-bridgeto your Unity project via "add package from disk". - You should have
uvinstalled so it can run and automatically update the server's dependencies. Add the MCP Server in/mcp-editor-bridgeto your preferred IDE Agent's list of MCP servers. The MCP server POSTs to the Unity Editor's HTTP listener athttp://127.0.0.1:1073/mcp.
"mcpServers": {
"unity-semantic-bridge": {
"command": "uv",
"args": [
"--directory", "<YOUR_LOCAL_PATH_TO_/unity-semantic-bridge/mcp-editor-bridge>",
"run", "main.py"
]
}
}
- In Unity, from the Tools menu, select "Unity Semantic Bridge" > "Start HTTP Listener" (port 1073). Your IDE Agent now has access to your Unity Project and MCP tools provided. Health check:
GET http://127.0.0.1:1073/health.
Available Tools
Human-Agent Cowork
get_recent_unity_events— Returns Unity Editor events (hierarchy/selection/play-mode/console/objectChangedviaObjectChangeEvents.changesPublished) pushed since a time window — use to see human edits,add_component/remove_component/set_field_valuesetc.notify_unity— Sends a message to the Unity Editor chat window (BridgeRelay.OnAgentMessage).
Project & Settings
get_project_settings— Returns Unity Project Settings as JSON. Selectively fetchcore(Unity version, build target),rendering(URP asset, color space, MSAA),input(Input Handling,inputactionsassets),ui(uGUI vs UI Toolkit counts),scripting(API level, define symbols, backend),tags_layers.
Scene & GameObject Inspection
get_scene_hierarchy— Returns the scene as a list of GameObjects with paths and instance IDs. Usually the first tool to call. Supports depth limiting, a node cap with truncation reporting (for large scenes), optional filtering to only main-camera-visible objects, androot_instance_idsubtree queries.get_gameobject_tree— Full hierarchy under a specific GameObject (faster thanget_scene_hierarchyfor rigs; avoidsSkinnedMeshRendererpruning).inspect_gameobject— Detailed inspection of a GameObject including components and public fields (usesComponentInspectorwith expandedGenericstructs).get_component_inspector_values— All serialized field values visible in the Inspector for a specific component (live Editor values, expandsRigBuilder/Rig/*Constraint.m_Data/Transform.m_LocalRotationas structuredquat+euler).get_component_code— Locates and returns the full C# source for a named component (MonoScriptviaAssetDatabase).get_unity_physics_layers— Physics layer collision matrix (Physics.GetIgnoreLayerCollision).
Scene & GameObject Authoring (Hierarchy & Rigging)
create_gameobject— Creates a newGameObject(new GameObject(name)) withUndo.RegisterCreatedObjectUndo, optionalparentInstanceIdviaSetParent(parent,false), and optionallocalPosition/localRotation({x,y,z,w}or{euler}) /localScale. Returns{instanceId,path}.duplicate_gameobject— Duplicates a hierarchy viaInstantiate+Undo.RegisterCreatedObjectUndo(use for cloning whole rig layers, e.g.Rig Layer (Rifle Idle)). Returns{instanceId,path}.set_parent— Reparents viaUndo.SetTransformParent(orRegisterCompleteObjectUndo+SetParentwhenkeepWorldPosition:true). Passnullto unparent to root.delete_gameobject— Deletes aGameObjectviaUndo.DestroyObjectImmediate(supports Undo).copy_component— Deep-copies a component viaUndo.AddComponent+EditorUtility.CopySerialized(required for Animation RiggingConstraint.datastructs wherem_Data: [Generic]cannot be rebuilt viaset_field_values). Returns{targetComponentIndex,targetInstanceId}.add_component— Adds a component byinstance_id(Type.GetType+ assembly fallback, respectsallowDuplicate).remove_component— Removes a component byinstance_id(Undo.DestroyObjectImmediate).set_field_values— Sets one or more serialized field values viaSerializedObject/FindProperty+Undo.RecordObject(supports primitives, enums as strings,Vector2/3,Quaternion,Color,ObjectReferenceasinstanceId,Generic/ArrayforRigBuilder/Constraintdata).
Assets & ScriptableObjects
find_unity_files— Finds assets in Unity viaAssetDatabase.FindAssets(t:Prefab,l:Label, etc.), defaultfolders:['Assets'].find_asset_references— Finds assets/scenes referencing a specific asset path (AssetDatabase.GetDependencies).get_project_tree— Project folder structure from a path (AssetDatabase.GetSubFolders+ direct-file filter).write_unity_script— Creates/overwrites a C# script (Assets/...cs) and triggers recompilation (AssetDatabase.ImportAsset/Refresh,CONFIRM_REQUIREDpattern).create_scriptable_object— Creates aScriptableObjectasset atomically withoutwrite_unity_script:Type.GetType+ assembly fallback,ScriptableObject.CreateInstance, field init viaSerializedObject(primitives, enums as"cross"→UnitId.cross,Vector3{x,y,z},Objectrefs asinstanceId/guid/{fileID,guid}),Undo.RegisterCreatedObjectUndo+AssetDatabase.CreateAsset/SaveAssets/Refresh. ValidatesAssets/+.asset, parent folder exists,ScriptableObjectsubclass,CONFIRM_REQUIREDon overwrite. Returns{instanceId,guid,path}.delete_asset— Deletes an asset viaAssetDatabase.DeleteAsset(supports Undo, validatesAssets/).get_compilation_status— Non-blocking snapshot of compilation (PENDING/SUCCESS/FAILEDwith errors) — poll afterwrite_unity_script.
Editor & Runtime
get_screenshot— Capturesgame(Camera.main) orscene(Scene view) as JPEG;scenecanFrameafocus_instance_idbounds before capture.set_unity_play_mode— Enters/exits Play Mode (EditorApplication.isPlayingviadelayCall).get_unity_console_logs/clear_unity_console_logs— Read last 10 errors/warnings viaLogEntriesreflection or clear (LogEntries.Clear).
Lighting Diagnostics
get_lights_affecting_object— Lights within range of a target object using actual bounds distance, per-lighttype/intensity/range/cullingMask(usesGetLightsAffectingObject).get_urp_pipeline_settings— URP asset’s current render path setting (GetUrpPipelineSettings).diagnose_lighting_issue— Autonomous diagnostic subagent (lights → URP → renderer/materials) viacore.llm_provider; seeLightingAgent/README.md. RequiresLIGHTING_LLM_PROVIDER/MODEL+ API key.
Known Limitations (for Agents using this tool to read)
- Unity instance IDs are not stable across script recompiles or domain reloads. Any C# change invalidates previously-fetched instance IDs — re-run
get_scene_hierarchyafter recompiling before reusing an ID from an earlier call. - The Editor connection is single-flight. Only one MCP request is processed at a time; overlapping calls queue rather than run concurrently, since Unity's Editor-side message handling is inherently serial.
Installing Unity Semantic Bridge
This server has no published package — it is built from source. Open the repository and follow its README.
▸ github.com/Programalyst/unity-semantic-bridgeFAQ
Is Unity Semantic Bridge MCP free?
Yes, Unity Semantic Bridge MCP is free — one-click install via Unyly at no cost.
Does Unity Semantic Bridge need an API key?
No, Unity Semantic Bridge runs without API keys or environment variables.
Is Unity Semantic Bridge hosted or self-hosted?
Self-hosted: the server runs locally on your machine via the install command above.
How do I install Unity Semantic Bridge in Claude Desktop, Claude Code or Cursor?
Open Unity Semantic Bridge on unyly.org, pick your client tab (Claude Desktop, Claude Code, Cursor) and press Install — the config is generated automatically, no JSON editing.
Related MCPs
Fetch
Web content fetching and conversion for efficient LLM usage.
AWS KB Retrieval
Retrieval from AWS Knowledge Base using Bedrock Agent Runtime.
by modelcontextprotocolSpring AI MCP Server
Provides auto-configuration for setting up an MCP server in Spring Boot applications.
llm-analysis-assistant
A very streamlined mcp client that supports calling and monitoring stdio/sse/streamableHttp, and can also view request responses through the /logs page. It also
by xuzexin-hzMCP-Agent
A simple, composable framework to build agents using Model Context Protocol by [LastMile AI](https://www.lastmileai.dev)
by lastmile-aiSpring AI MCP Client
Provides auto-configuration for MCP client functionality in Spring Boot applications.
mcp.natoma.ai
A Hosted MCP Platform to discover, install, manage and deploy MCP servers by [Natoma Labs](https://www.natoma.ai)
MCPHub
Website to list high quality MCP servers and reviews by real users. Also provide online chatbot for popular LLM models with MCP server support.
MCP Servers Rating and User Reviews
Website to rate MCP servers, write authentic user reviews, and [search engine for agent & mcp](http://www.deepnlp.org/search/agent)
mkinf
An Open Source registry of hosted MCP Servers to accelerate AI agent workflows.
Compare Unity Semantic Bridge with
Not sure what to pick?
Find your stack in 60 seconds
Author?
Embed badge for your README
Browse similar
All ai MCPs
