matlab-build-simbiology-model
Build, modify, and diagram SimBiology models — API reference, helper functions, and layout patterns. Use when constructing or editing models programmatically or visually.
npx skills add matlab/matlab-agentic-toolkit --skill matlab-build-simbiology-model --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
What it does
Build, modify, and diagram SimBiology models using API references, helper functions, and layout patterns. Intended for constructing or editing models programmatically or visually, with diagram features activated when the user requests visual output via the Model Builder.
How it works
The skill instructs users to: add and modify compartments, species, parameters, and reactions using standard SimBiology API (e.g., addcompartment, addspecies, addparameter, addreaction); follow rules for reaction direction and qualified naming; use modern property names (Value, Units, Constant); and manage the Model Builder/Analyzer lifecycle to preserve diagrams when requested. It provides helper functions (in scripts/) such as getModelByUUID, addAndPositionCompartment (to create a compartment with species in one step for diagrams), checkDiagramLayout, repositionAllReactions, positionAncillaryBlocks, and openLiveBuilder. For diagram workflows, it prescribes a sequence: open Builder, plan positions, build compartments with addAndPositionCompartment, then add parameters/reactions/rules/doses/events, run layout checks, reposition reactions, and finally position ancillary blocks. It also includes patterns for safe opening of the Builder and guidelines to avoid closing the Builder mid-modification. It lists API references for common operations (Model, Compartments, Species, Parameters, Reactions, Rules/Events/Doses, Observables/Variants, Simulation Config, and Selection).
When to use it
- Building or modifying SimBiology models (compartments, species, reactions, parameters, rules, events, doses, observables, variants)
- Opening, saving, or loading models in the Model Builder / Analyzer apps
- Designing or adjusting diagram layouts
- Keywords include: build, create, modify, add compartment/species/reaction, diagram, layout
What it can touch
- MATLAB environment requires adding helper scripts to path: addpath(fullfile('<WORKSPACE_ROOT>', '.claude', 'skills', 'matlab-build-simbiology-model', 'scripts'));
- Uses functions from scripts/ such as getModelByUUID, addAndPositionCompartment, checkDiagramLayout, computeSafeReactionPosition, repositionAllReactions, positionAncillaryBlocks, openLiveBuilder, isAppOpen, loadViaBuilder, saveViaBuilder, and diagram utilities like simbio.diagram.*. Commands and file names are referenced exactly as shown in the skill.
- Example code snippets use MATLAB commands: sbiomodel, addcompartment, addspecies, addparameter, addreaction, addkineticlaw, PKModelDesign, loadViaBuilder, loadViaBuilder(filePath), sbioreset, simBiologyModelBuilder, isAppOpen, getModelByUUID, addAndPositionCompartment, checkDiagramLayout, repositionAllReactions, positionAncillaryBlocks, computeSafeReactionPosition, simbio.diagram.setBlock, and related properties like Value, Units, Constant.
Caveats
- Diagram features require the Model Builder app and are activated only when the user requests visual output.
- The rules emphasize using qualified names for species and reaction-scoped parameters and adopting modern property names (Value, Units, Constant).
- Diagram layout steps are conditional on user request; for pure model construction, diagram steps are skipped.
- The approach involves managing Builder state (opening/closing) to avoid orphaned windows or conflicts when sbioreset is called.
- No guarantees of successful diagram rendering beyond the scripted checks (checkDiagramLayout outcomes must indicate zero violations before presenting diagrams).
# Build SimBiology Models API reference, helper functions, and patterns for building, modifying, and diagramming SimBiology models. Works in all MATLAB environments (desktop, headless, batch, remote). Diagram/layout features require the Model Builder app and are activated only when the user requests visual output. ## When to Use - Building or modifying SimBiology models (compartments, species, reactions, parameters, rules, events, doses, observables, variants) - Opening, saving, or loading models in the Model Builder / Analyzer apps - Designing or adjusting diagram layouts - Keywords: "build", "create", "modify", "add compartment/species/reaction", "diagram", "layout" ## When NOT to Use - Simulation and analysis (use `matlab-simulate-simbiology-model`) - Parameter fitting, population modeling, NCA (use `matlab-fit-simbiology-model`) ## Must-Follow Rules ### 1. Add helper scripts to the MATLAB path first Run at the start of every session: ```matlab addpath(fullfile('<WORKSPACE_ROOT>', '.claude', 'skills', 'matlab-build-simbiology-model', 'scripts')); disp('Helper scripts added to path.') ``` ### 2. Only open the Builder when needed Do NOT open the Model Builder by default. Open it w
- When to Use
- When NOT to Use
- Must-Follow Rules
- 1. Add helper scripts to the MATLAB path first
- 2. Only open the Builder when needed
- 3. Model construction uses standard SimBiology API
- 4. Write reactions in the biological forward direction
- 5. Always use qualified names for species and reaction-scoped parameters
- 6. Use modern property names (Value, Units, Constant)
- 7. Close Builder and Analyzer before sbioreset
- 8. Diagram rules (only when user requests a diagram)
- Helper Functions (scripts/)
- Model construction (always available)
- Diagram & Builder (only when user requests diagram/layout)
What does the matlab-build-simbiology-model skill do?
Build, modify, and diagram SimBiology models — API reference, helper functions, and layout patterns. Use when constructing or editing models programmatically or visually.
How do I install it?
Run `npx skills add matlab/matlab-agentic-toolkit --skill matlab-build-simbiology-model --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From matlab/matlab-agentic-toolkit, a repository with 868 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
