mcpField
M
Maibaamvfx

Maibaamvfx

Local
github.com/MABAAMMedia & Design3Updated 29w ago

About Maibaamvfx

Maibaamvfx is an MCP server for parsing and generating VFX file formats, aimed at tools and workflows that handle Nuke, MaterialX, and USD ASCII text. It transforms text and JSON ASTs without filesystem access, with round-trip stability.

Key features

  1. 01Parse Nuke .nk to JSON AST
  2. 02Parse MaterialX .mtlx to JSON AST
  3. 03Parse USD ASCII .usda to JSON AST
  4. 04Generate all three formats
  5. 05Read-only text transformations
  6. 06Round-trip stable parsing and generation

Use cases

  1. 01Inspecting Nuke node graphs and properties
  2. 02Processing MaterialX shading networks
  3. 03Reading and generating USD ASCII scene layers

MCP support

The server exposes six MCP tools for parsing and generating Nuke `.nk`, MaterialX `.mtlx`, and USD ASCII `.usda` files. Tools operate on text and do not access the filesystem.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

mcp.json · Universal config
{
"mcpServers": {
"vfx-parsers": {
"command": "npx",
"args": [
"-y",
"mcp-vfx-parsers"
]
}
}
}
Run commandnpx -y mcp-vfx-parsers

Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.

Packages
npmmcp-vfx-parsers

Tools

6

Saved tool list · updated 2w ago

ParameterTypeRequiredDescription
textstringYesThe .nk script text to parse

Details

From the project README

mcp-vfx-parsers

MCP server for VFX file format parsing. Parse and generate Nuke .nk, MaterialX .mtlx, and USD ASCII .usda files — all via the MCP stdio protocol. Round-trip stable.

Tools

ToolDescription
parse_nukeParse .nk script → JSON AST (nodes, properties, DAG wiring)
parse_mtlxParse .mtlx XML → JSON AST (node graphs, inputs, materials)
parse_usdaParse .usda text → JSON AST (prims, attributes, variants, connections)
generate_nukeJSON AST → .nk script (round-trip stable)
generate_mtlxJSON AST → .mtlx XML (round-trip stable)
generate_usdaJSON AST → .usda text (semantic round-trip)

All tools are read-only — they transform text, never touch the filesystem.

Install

npx -y mcp-vfx-parsers

Usage with Claude Code

Add to your Claude Code MCP settings (~/.claude/settings.json):

{
  "mcpServers": {
    "vfx-parsers": {
      "command": "npx",
      "args": ["-y", "mcp-vfx-parsers"]
    }
  }
}

Usage with Claude Desktop

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "vfx-parsers": {
      "command": "npx",
      "args": ["-y", "mcp-vfx-parsers"]
    }
  }
}

Supported Formats

Nuke .nk

Foundry Nuke compositing scripts. Parses the TCL-based stack-wired node graph format:

  • Node types, properties, positions
  • Input wiring via set/push stack directives
  • Root settings (merges duplicate Root blocks)
  • TCL expressions and UserKnob blocks (preserved as opaque text)
  • Escape sequences in quoted values (\", \\, \n, \t, \r, \0)
MaterialX .mtlx

MaterialX shading network definitions. Parses the XML-based format:

  • Node graphs with typed inputs/outputs
  • Material assignments
  • nodename connection references (DAG edge extraction)
  • Attribute preservation (quote style, order)
  • Comments and XML prolog
  • XML entity encoding/decoding (&, {, )
USD ASCII .usda

Pixar Universal Scene Description (ASCII layer format). Full grammar support:

  • Prim hierarchy (def, over, class)
  • Typed attributes with uniform/custom modifiers
  • .connect connections (UsdShade node graphs)
  • .timeSamples animation data
  • Relationships (single + array targets)
  • VariantSets with nested variant bodies
  • Composition arcs: references, payloads, inherits, specializes
  • Layer and prim metadata
  • Triple-quoted strings and asset paths (@...@, @@@...@@@)

Round-Trip Guarantee

All parsers maintain a strict round-trip invariant:

parse(generate(parse(input))) === parse(input)

Nuke and MaterialX produce byte-identical output. USDA produces semantically identical output in canonical pretty-print form (comments stripped — documented limitation).

Safety & Robustness

  • Input size limit: All tools reject inputs larger than 10 MB
  • Malformed JSON: Generate tools return clear error messages instead of crashing
  • No filesystem access: Pure text transforms, safe for sandboxing
  • No eval/exec: No dynamic code execution
  • No external dependencies: Only @modelcontextprotocol/sdk
  • XXE-safe: MaterialX parser does not evaluate DOCTYPE/entity declarations
  • Unicode: Full UTF-8 support across all three parsers

Development

git clone https://github.com/MABAAM/mcp-vfx-parsers.git
cd mcp-vfx-parsers
npm install
npm test
node src/server.mjs

Changelog

v0.2.0
  • Server hardening: JSON.parse() wrapped in safe handler — malformed input returns error instead of crashing the MCP server
  • Input size limits: All 6 tools reject inputs > 10 MB to prevent memory exhaustion
  • Nuke duplicate Root: Multiple Root blocks are merged (later values win) instead of silently discarding the first
  • Nuke escape sequences: unquote() now handles \n, \t, \r, \0 in addition to \" and \\
  • USDA data preservation: Non-path values in .connect arrays and relationship targets are preserved as <INVALID:kind:value> instead of silently dropped
v0.1.0
  • Initial release: 3 parsers (Nuke, MaterialX, USDA), 6 MCP tools, 13 tests

License

MIT

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.