procedural-blender-nodes — Claude Code rule
The procedural-blender-nodes rule for Claude Code guides AI in building and editing node trees via bpy scripts. It enables precise control over procedural generators and Blender 5.x node systems.
MIT ★ 101 updated 2026-10-21
.cursor/rules/procedural-blender-nodes.mdcWhat procedural-blender-nodes does
This rule instructs AI when generating Python scripts for Geometry Nodes, Shader Nodes, and the compositor. It manages graph structures, instancing of NK library groups, and time-based input handling for animated nodes. For Blender 5.2 workflows, the rule mandates using specific inspectors instead of direct socket manipulation to ensure structural integrity.
Integration requires an existing Blender environment and active bpy scripts. The agent uses this configuration to enforce linting and validation standards; after building with build.py, the system verifies output using scripts/validate.py to ensure zero warnings in .blend files. The rule file should be placed in .claude/rules/ or the appropriate configuration folder for the IDE agent.
What it helps with
- Automating procedural node tree construction
- Validating Blender node graph integrity
- Porting custom scripts to Blender 5.x
- Managing animated group inputs and modifiers
Example prompts for the agent
- Generate a
build.pyscript for the terrain generator using procedural-blender-nodes. - Validate the current blend file for node warnings using
scripts/validate.py. - Update modifier inputs using
nodekit.inspect.set_modifier_inputsto comply with Blender 5.2 standards.
How to install procedural-blender-nodes
Manually: put the files in place
.cursor/rules/procedural-blender-nodes.mdcFrontmatter: description, globs, alwaysApply
1Plugin marketplace
/plugin marketplace add gokayfem/video-to-blender/plugin install video-to-blender@video-to-blender2Manually: put the files in place
.claude/rules/procedural-blender-nodes.mdThe paths frontmatter field limits the files: move globs from the source into paths
AGENTS.md
Codex reads AGENTS.md: paste the rule text there
Manually: put the files in place
.github/instructions/procedural-blender-nodes.instructions.mdThe applyTo field sets which files it applies to: move globs from the source into applyTo
Manually: put the files in place
.devin/rules/procedural-blender-nodes.mdManually: put the files in place
.clinerules/procedural-blender-nodes.mdStep by step, with commands for each platform: Cursor rules: .mdc files, four modes and what replaced .cursorrules
Questions about procedural-blender-nodes
How to install procedural-blender-nodes in Claude Code?
Run /plugin marketplace add gokayfem/video-to-blender, then /plugin install video-to-blender@video-to-blender, and save the rule to .claude/rules/procedural-blender-nodes.md.
What does procedural-blender-nodes do?
It provides coding standards for bpy scripts, including group management, input naming conventions, and proper handling of scene time and random attributes in nodes.
What is required for procedural-blender-nodes to work?
The rule requires Blender installed on the system and a Python environment capable of running bpy for building and validating node-based setups.
Source text
procedural-blender-nodes.mdc · MIT
---
description: Blender bpy scripts that build or edit node trees (Geometry Nodes, Shader Nodes, compositor), procedural generators, Blender 5.x ports
globs: **/*.py
alwaysApply: false
---
Copy this file into your project's `.cursor/rules/`. It applies to Python files that use `bpy` to build node systems;
ignore it for other Python. Install the skill too (Cursor reads `~/.cursor/skills`, `~/.claude/skills` and
`.agents/skills`), so the rule can point at it.
- Use the `procedural-blender-nodes` skill: route the subject with `references/subject-routing.md`, find groups with
`scripts/nodes_tools.py search`, build every group with nodekit's `Graph`, and instance `NK` library groups
instead of rewriting them.
- Every group and input has a description; inputs have ranges and subtypes and sit in panels (a Primary panel first);
each block is in a labelled frame.
- Animated groups take a `Time` input in seconds; only the top-level modifier group reads Scene Time.
- Per-piece variation reaches materials as `nk_color` (FLOAT_COLOR) and `nk_rand` (FLOAT 0..1) attributes.
- Shared groups are built once (`@nodegroup` or `nodekit.graph.once`); rebuilding one unlinks its users.
- Blender 5.2: never `mod["Socket_N"]`; use `nodekit.inspect.set_modifier_inputs(mod, {"Name": value})`. Modes on
Transform, Resample and Set Curve Normal are input sockets.
- Run Blender as `blender -b --factory-startup --python build.py`, then `scripts/validate.py` on the saved .blend;
zero node warnings, zero lint.
© gokayfem · MIT · gokayfem/video-to-blender