SmartHopper.Core.Grasshopper
The Grasshopper-facing layer: everything that touches the canvas, the document, data trees, and GhJSON — plus the AI tool catalog the assistant and MCP server expose.
AITools/
Implementations of AITool — the verbs the assistant can perform:
- Canvas read/edit:
gh_get,gh_put,gh_connect,gh_tidy_up,gh_move,gh_group,gh_remove,gh_select,gh_diff,gh_merge,gh_patch_apply,gh_patch_validate,gh_clear,gh_component_lock,gh_component_preview,gh_document_save,gh_generate,gh_report… - Discovery:
gh_list_components,gh_list_categories,smarthopper_readme,smarthopper_workflows,smarthopper_tool_help,smarthopper_ghjson_reference. - Scripting:
script_generate,script_edit,script_review,ScriptCodeValidator. - Media:
text2img,img2text,speech_generate,screenshots(canvas & viewport),canvas_view,canvas_point. - Knowledge:
web2md,file2md,discourse_*tools for McNeel, Ladybug, and generic forums. - Data:
text2text,text2textlist,text2boolean,textlist2boolean,text2json,list_filter. - Interaction:
ask_user,button_click,plan_propose,plan_tasks,set_ai_provider_and_model.
Each tool declares MutatesCanvas, Enabled, Category, Tags, and MCP annotations — those flags drive MCP exposure and the consent pipeline. See the MCP server page.
GhJsonSpec/
GhJsonSpecLoader — embedded GhJSON/GhPatch specification used for validation and served to AI clients as docs:///ghjson-schema.
Converters & Utils
GhJSON ↔ Grasshopper object converters, canvas helpers (Canvas), Rhino interop (Rhino), JToken utilities, and parsing helpers shared by tools and components.