A Grasshopper plug-in that provides a full round-trip workflow between Grasshopper and Space Gass structural analysis via the Space Gass REST API.
Build parametric structural models in Grasshopper, push them to Space Gass, run analysis, and pull results back — all without leaving the canvas. Open existing Space Gass models and inspect their structure, properties, and loads directly on the canvas.
- Parametric modelling — Define members, plates, sections, materials, restraints, releases, offsets, and node constraints with standard Grasshopper data flow.
- Full load support — Node loads, member distributed/concentrated/prestress loads, self-weight, lumped mass, prescribed displacements, plate pressure, and thermal loads.
- Multiple analysis types — Linear static, non-linear static, buckling, and dynamic frequency analysis with configurable settings.
- Results extraction — Node reactions, node displacements, member forces, member displacements, buckling results, dynamic frequency results, and plate forces — all as Grasshopper data trees.
- Disassemble existing models — Read structure, properties, load cases, and all load types from an existing Space Gass job back into Grasshopper via query components.
- Append mode — Add structure and loads to an existing model without clearing, enabling hybrid workflows between manual Space Gass modelling and Grasshopper.
- Async execution — All API-calling components run on background threads. The canvas stays responsive during model assembly, analysis, and results queries.
- Smart value lists — Enum inputs auto-populate with value lists on component placement.
| Requirement | Version |
|---|---|
| Rhino | 8 |
| Space Gass | 14.5+ with REST API (beta) |
| .NET | 8.0 |
Search for gh-space-gass in the Rhino Package Manager and install.
git clone https://github.com/mitchell-tesch/GhSpaceGass.git
cd GhSpaceGass
dotnet build
Copy the built .gha and dependencies from GhSpaceGass/bin/Debug/net8.0/ to your Grasshopper libraries folder.
- Connect — Drop an
SG Connectcomponent, setConnect?totrue. The plug-in launches the Space Gass API service automatically. Provide a.sgfile path to open an existing model, or leave blank for a new temporary job. - Define structure — Use
SG Section,SG Material,SG Member,SG Plate,SG Restraint,SG Member Release,SG Member Offset, andSG Node Constraintto define your structural model. - Add loads — Create load cases with
SG Load Case(and optionallySG Load CategoryandSG Combination Load Case). Apply loads withSG Node Load,SG Member Distributed Load,SG Member Concentrated Load,SG Member Prestress Load,SG Self-Weight Load,SG Lumped Mass Load,SG Prescribed Displacement,SG Plate Pressure Load, andSG Thermal Load. - Assemble — Connect everything into
SG Assemble Modeland setAssemble?totrue. The model is pushed to Space Gass. Use Append mode to add to an existing model without clearing. - Analyse — Feed the model into
Run Analysis, select the analysis type, configure optional settings, and setRun?totrue. - Results — Use results components to extract analysis data back into Grasshopper as structured data trees.
- Disassemble — Use
SG Disassemble Modelto read an existing Space Gass model, then query its properties and loads with theSG Getcomponents.
All components live under the SpaceGass tab in Grasshopper.
| Panel | Components |
|---|---|
| Connection | SG Connect, SG Job Info, SG Save Job |
| Properties | SG Section, SG Material, SG Get Sections, SG Get Materials |
| Structure | SG Member, SG Restraint, SG Member Release, SG Member Offset, SG Node Constraint, SG Plate |
| Cases | SG Load Case, SG Combination Load Case, SG Load Category, SG Get Load Cases |
| Loads | SG Node Load, SG Member Distributed Load, SG Member Concentrated Load, SG Member Prestress Load, SG Self-Weight Load, SG Lumped Mass Load, SG Prescribed Displacement, SG Plate Pressure Load, SG Thermal Load, SG Get Self-Weight Loads, SG Get Node Loads, SG Get Member Loads, SG Get Plate Loads |
| Model | SG Assemble Model, SG Disassemble Model |
| Analysis | SG Static Analysis Settings, SG Buckling Analysis Settings, SG Dynamic Frequency Settings, Run Analysis |
| Results | SG Node Reactions, SG Node Displacements, SG Member Forces, SG Member Displacements, SG Plate Forces, SG Buckling Results, SG Dynamic Frequencies |
GhSpaceGass/ # Grasshopper plug-in — components, icons, async infrastructure
GhSpaceGass.Core/ # Core library — session management, API wrapper, model assembler
GhSpaceGass.Tests/ # Unit tests (xUnit + NSubstitute)
adr/ # Architecture Decision Records
The plug-in follows a deferred-push pattern:
- Builder components (Create Member, Create Restraint, etc.) construct in-memory data objects without making API calls.
- Assemble Model collects all builder outputs, deduplicates geometry, and pushes the complete model to Space Gass via bulk API calls in dependency order. Supports Rebuild (default — clear and push) and Append (add to existing) modes.
- Disassemble Model reads an existing model from Space Gass and outputs geometry plus a Model object for downstream chaining.
- Get components query specific data (sections, materials, load cases, loads) from the open job.
- Run Analysis submits analysis and polls for completion.
- Results components query the API and return structured data trees.
A singleton SpaceGassSession manages the API service lifecycle. The plug-in launches the service automatically on connect and terminates it on disconnect (if it started it). If the service is already running, it reuses the existing instance.
All async components use a deferred runtime message pattern — messages are queued during background execution and replayed on the UI thread during output, ensuring error badges and warnings display correctly.
Design decisions are recorded in the adr/ folder.
If you're a coding agent (GitHub Copilot, Claude Code, Cursor, Codex CLI, Aider, JetBrains AI Assistant, …) working in this repository, start with AGENTS.md — it covers conventions, architecture, the SPACE GASS API reference (https://api.spacegass.com/docs/llms-full.txt), and the slice-based workflow. GitHub Copilot also auto-loads .github/copilot-instructions.md, which points to the same guide.
MIT © Mitchell Tesch