grasshopper-generator

Generate Rhino 7 Grasshopper (.ghx) XML files from natural language descriptions or images. Build parametric definitions with native GH components, GhPython scripts, and wiring. Supports concept design: twisted towers, curved facades, Voronoi patterns, diagrids, parametric surfaces, mesh operations, and custom Python geometry. Triggers: grasshopper, generate ghx, parametric definition, GH file, grasshopper definition, 参数化, 生成gh文件, when user wants a .ghx file.

Safety Notice

This listing is from the official public ClawHub registry. Review SKILL.md and referenced scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "grasshopper-generator" with this command: npx skills add elliotbian/grasshopper-generator

Grasshopper Generator

Generate Rhino 7 Grasshopper (.ghx) files programmatically.

Workflow

1. Analyze Input

Image → Identify form (tower/dome/surface/facade), key features (twist/array/voronoi/diagrid), proportions. Text → Parse the same from description.

2. Design the Graph

Sliders → Geometry → Transforms → Booleans → Output

Component priority:

  1. Native GH components (see references/component_guids.json for 152 known GUIDs)
  2. GhPython Script for complex custom logic
  3. Third-party plugins only when explicitly requested

Common patterns:

FormKey Components
Twisted towerRectangle → Rotate → Extrude → Series
Curved facadeCurve → Divide → Orient → Surface
VoronoiPopulate 2D → Voronoi → Boundary Surfaces
DiagridHexagonal → Scale → Loft
DomeCircle → Rotate → Sweep1
Custom logicGhPython Script

3. Generate .ghx

import sys; sys.path.insert(0, 'SKILL_DIR/scripts')
from ghx_generator import GHXGenerator

gen = GHXGenerator("Definition Name", "Description")
r = gen.add_slider("Radius", 20, 1, 100, x=50, y=50)
c = gen.add_component("Circle", inputs=["Base Plane", "Radius"], outputs=["Circle"], x=300, y=50)
gen.connect(r, "output", c, "Radius")
gen.save("output.ghx")

4. GhPython Fallback

For complex geometry not achievable with native components:

py = gen.add_python("Custom", code, inputs=["x", "y"], outputs=["a"], x=300, y=200)

GhPython has full Rhino.Geometry API. Input variables available by name. Assign a = result for output.

5. Deliver

Save .ghx and send to user. Note adjustable parameters (sliders), definition purpose, and any plugin dependencies.

File Locations

  • Generator: scripts/ghx_generator.py — full API with add_slider, add_component, add_python, connect, save
  • GUID database: references/component_guids.json — 152 authentic component GUIDs extracted from real .gh files
  • Reference template: references/template_voronoi.ghx — real Grasshopper file for structural reference

Notes

  • Output is .ghx (XML), fully compatible with Rhino 7
  • All GUIDs extracted from real Grasshopper installations
  • For components not in the database, GhPython Script handles everything
  • Supports wiring via connect(source_ref, source_param, target_ref, target_param)

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

Web3

ERC-800Claw

The OpenClaw entry point for ERC-8004 agent identity and reputation. Register agents on-chain, query identities, give and receive feedback ratings.

Registry SourceRecently Updated
Web3

End-to-end encrypted messaging and EVM crypto wallet for agent identity

End-to-end encrypted messaging for AI agents. Register unique usernames and send cryptographically private messages with blinded inboxes. Create encrypted group chats with Sender Keys protocol. Set your profile with username, description, public key and EVM crypto address. Search for other AI agents based on their usernames and descriptions. Also supports multi-chain crypto transfers (ETH, Base, BSC) to @username.

Registry SourceRecently Updated
Web3

Clawpay

Private payments for AI agents - no on-chain link between sender and recipient

Registry SourceRecently Updated
Web3

Typhoon Starknet Account

Create an anonymous Starknet wallet via Typhoon and interact with Starknet contracts. Privacy-focused wallet creation for agents requiring anonymity.

Registry SourceRecently Updated
2.4K1Profile unavailable