BD

bpy-dev/blender-mcp

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

97 stars 9 forks 质量 73 趋势 23GPL-3.0

Blender Lab MCP 的独立增强版:独立的 bpy、运行时 API 文档和基准测试工具

概览

该分支为Blender代理工作打包了增强版的Blender MCP工作流程。它保留了上游实时的Blender插件/服务器模型,并增加了保存文件/无头执行、可选命令行后端、运行时Blender Python API查找、子进程/捕获加固以及基准测试工具。 这是 Blender Lab 的 Blender MCP 项目的修改版。有关执行风险模型的来源和 SECURITY.md 请参见 NOTICE.md。公共 bpy.dev 网站资产将存放在独立的仓库中。 该合集涵盖 。其视频中的“剪辑准确性”标签表示 。链接的不可变 H.264 视频为 848×464,134.9秒,10,161,884字节;SHA-256:04966320de680203baed6c01c3e211059350454139dc8a802c557cce24815c17。 - _for_cli工具可在新子进程中运行.blend文件,无需实时Blender界面会话。- 使用Blender可执行后端或带有BLENDER_MCP_CLI_BACKEND的独立bpy Python后端。

概述(AI 翻译)

增强版MCP开发者预览

该分支为Blender代理工作打包了增强版的Blender MCP工作流程。它保留了上游实时的Blender插件/服务器模型,并增加了保存文件/无头执行、可选命令行后端、运行时Blender Python API查找、子进程/捕获加固以及基准测试工具。

这是 Blender Lab 的 Blender MCP 项目的修改版。有关执行-风险模型的来源和 SECURITY.md 请参见 NOTICE.md。公共 bpy.dev 网站资产将存放在独立的仓库中。

BlenderBench 结果

该合集涵盖了27个任务/270发弹药。其视频中的“剪辑准确性”标签意味着 CLIP 图像嵌入余弦相似度,而非字面准确性。链接的不可变函数 H.264视频为848×464,134.9秒,10,161,884字节;SHA-256: 04966320de680203baed6c01c3e211059350454139dc8a802c557cce24815c17。

什么是增强的

  • 保存文件工具: _for_cli 工具在新子进程中处理 .blend 文件,无需实时 Blender UI 会话。
  • 后端选择: 使用Blender可执行后端或独立的bpy)Python后端,配备BLENDER_MCP_CLI_BACKEND。

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

Blender MCP

Enhanced MCP developer preview

This branch packages an enhanced Blender MCP workflow for agentic Blender work. It keeps the upstream live Blender add-on/server model and adds saved-file/headless execution, selectable command-line backends, runtime Blender Python API lookup, subprocess/capture hardening, and benchmark tooling.

This is a modified distribution of Blender Lab’s Blender MCP project. See NOTICE.md for provenance and SECURITY.md for the execution-risk model. Public bpy.dev website assets will live in a separate repository.

BlenderBench result

The compilation covers 27 tasks / 270 rounds. Its on-video “CLIP accuracy” label means CLIP image-embedding cosine similarity, not literal accuracy. The linked immutable H.264 video is 848×464, 134.9 seconds, and 10,161,884 bytes; SHA-256: 04966320de680203baed6c01c3e211059350454139dc8a802c557cce24815c17.

What is enhanced

  • Saved-file tools: _for_cli tools operate on .blend files in fresh subprocesses without requiring a live Blender UI session.
  • Backend selection: use a Blender executable backend or a standalone bpy Python backend with BLENDER_MCP_CLI_BACKEND.
  • Runtime API lookup: agents can query exact signatures, enums, defaults, and availability from the active Blender/bpy runtime instead of relying only on bundled docs.
  • Process isolation: command-line executions are bounded by explicit timeouts, output caps, compact JSON framing, and source-file overwrite checks. This is crash/process-state isolation, not an OS sandbox.
  • Benchmark tooling: deterministic token-efficiency tasks, exploratory creative comparison harnesses, and a portable model-neutral full-27 BlenderBench runner with pinned inputs and post-generation scoring.

Current publication status

Developer-preview cleanup is in progress. Before publishing, complete PUBLICATION_CHECKLIST.md, especially package naming, fresh-clone install smoke tests, and tracked-file secret scanning.

Overview

A lightweight MCP (Model Context Protocol) server for Blender. It offers a natural language interface with Blender’s Python API, improving access to documentation, and allowing users to explore and understand complex setups.

Read the documentation at blender.org/lab/mcp-server


The project is deliberately small, maintainable, and does no more than necessary. It has two components that communicate over a TCP socket:

  • A Blender add-on that runs inside Blender and executes live-scene requests.
  • An MCP server that runs as a separate process, launched by the
在 GitHub 查看完整 README

安装

This server does not publish a one-line install command.

Open the repository installation guide 新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "blender": { "command": "uv", "args": [ "--directory", "/absolute/path/to/blender_mcp/mcp", "run", "blender-mcp" ], "env": { "BLENDER_MCP_CLI_BACKEND": "bpy", "BLENDER_MCP_BPY_PYTHON": "/absolute/path/to/python-with-bpy" } } } }