Skip to main content

usdq

PyPI Python License

A command-line tool and Python library for authoring and composing OpenUSD scenes through structured JSON. Every command takes plain arguments and returns JSON, so scripts and LLM agents can build USD stages without importing pxr or writing .usda by hand. The surface is self-describing: usdq verbs emits the full machine-readable spec.

pip install usdq          # CLI + daemon + MCP server; usd-core is the only dependency
usdq verbs                # the full command surface as JSON (start here)
usdq mcp                  # serve every verb as MCP tools over stdio

Agents should read AGENTS.md for the JSON contract and canonical workflows; usdq with no arguments prints the same reference.

Status

Version 0.1.2, under active development. The command surface spans three areas:

  • Authoring & composition — prims and attributes, references and other composition arcs, variants, layers, collections, schemas, renaming, masked-write guards, and deferred-save sessions.
  • Geometry & shading — mesh arrays, tube and ribbon meshes, point instancers, HD primitives, and textured UsdPreviewSurface material networks.
  • Introspection & batching — verbs and schemas for discovery, batch for grouped execution.

The library wraps OpenUSD's pxr. The intended deployment is a thin client talking to a long-running daemon that holds the USD runtime, so repeated calls avoid repeated startup cost.

Run

pip install usdq                         # installs the `usdq` and `usdq-render` commands

usdq init /tmp/scene.usda --default-prim /World
usdq define-prim /tmp/scene.usda /World Mesh
usdq schema-info Mesh --pretty
usdq verbs --pretty

The first command auto-spawns a background daemon (per-user, on-demand) that owns the heavy USD runtime; subsequent calls reuse it. Pass --no-daemon to run in-process. For local development from a checkout: pip install -e ".[dev]".

Rendering

usdq-render adapters (usdrecord / blender / web-preview) require external tools that are not pip-installable — a full OpenUSD install for usdrecord (the usd-core wheel does not bundle it), Blender for Cycles + USD→glTF, and Chrome for web screenshots. Missing tools fail cleanly with renderer_not_found; core authoring needs none of them. See PORTABILITY.md for what survives across renderers.

Quality Gates

.venv/bin/ruff check --no-cache .
.venv/bin/pytest -q

# Optional local renderer smoke tests; not run by default in CI.
USDQ_RUN_REAL_RENDER_TESTS=1 .venv/bin/pytest -q -m real_render tests/test_render_cli.py

Design Contract

  • JSON success responses go to stdout.
  • Structured JSON errors go to stderr with non-zero exit codes.
  • set-attr refuses writes that would be silently masked by stronger root-layer-stack opinions unless --force is passed.
  • batch is deferred-save execution, not rollback-transactional execution: successful ops before a halt are persisted. The CLI exits non-zero if any submitted op fails, with the structured batch response on stderr.
  • begin-session / flush-session / end-session pin one stage across daemon requests and defer persistence until an explicit flush. Daemon auto-session remains opt-in through USDQ_AUTOSESSION=1.
  • The public CLI, core dispatch, and verbs manifest are generated from the same verb registry.

See DOCS.md for the full command reference and NOTES.md for the design log.

Metadata

Release files for usdq 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for usdq 0.1.2
File Size Uploaded Provenance Actions
usdq-0.1.2.tar.gz 188.9 kB Without provenance Details for usdq-0.1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for usdq 0.1.2
File Interpreter ABI Platform Actions
usdq-0.1.2-py3-none-any.whl Python 3 none any Details for usdq-0.1.2-py3-none-any.whl

Total release size: 310.7 kB

Release files / usdq-0.1.2.tar.gz

Download URL usdq-0.1.2.tar.gz
Size 188.9 kB
Tags Source
SHA-256 checksum
How to use checksums
e50af4ee841b98dcf9a0b39699d671743390bde06eb4c684783edccba37630f1
BLAKE2b-256 checksum
How to use checksums
d9d586f0a36d8d9b9300426d7cbe28d37b2f9186295ecfc4a05a4eb2f00595af
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.6

Release files / usdq-0.1.2-py3-none-any.whl

Download URL usdq-0.1.2-py3-none-any.whl
Size 121.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
14662fc15b1fca29db83927d2d3fc6dc07376ef162854154f0fa7a4484e242e7
BLAKE2b-256 checksum
How to use checksums
dbeb2ac272b5380dd124c0b2cec732c467b7963e84d55f1787f5ce4c74991720
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.6

Security for usdq 0.1.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page