本文へ移動
cccskills
無料GitHub で公開

configuring-block-policy

Guide users through creating and managing .satk/block-policy.json for controlling which blocks the agent can use, which are excluded, and which block parameters the agent should not modify. Use when setting up block usage policy for a project.

インストール方法を見る

含まれるファイル(2)

  • SKILL.md3.8 KB
  • manifest.yaml605 B

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Configuring Block Policy

Create or update .satk/block-policy.json — the file that controls which blocks (library or built-in) the agent can use, which are excluded, and which block parameters the agent should not modify.

When to Use

  • User asks to set up, create, or configure block policy
  • User asks to restrict or exclude blocks
  • User wants to prevent the agent from modifying certain block parameters
  • building-simulink-models routes here via the policy gate

When NOT to Use

  • Actively building a model → building-simulink-models
  • Improving block descriptions or categories → simulink-curating-library-kg
  • Declaring which libraries exist → Library Setup gate in building-simulink-models

Prerequisites

  • .satk/reuse-libraries.json must exist.

Workflow

  1. Check state — Does .satk/block-policy.json exist? If yes, load and summarize. If no, start fresh.
  2. Policy mode — (skip if no libraries specified) Ask: prefer libraries with built-in fallback, or custom libraries blocks only (no fallback)?
  3. Excluded blocks (optional) — Are there any blocks (library or built-in) that should never be placed in your models? Collect referenceBlock + reason.
  4. Off-limits parameters (optional) — Are there any block parameters you don't want the agent to modify? Collect referenceBlock + protectedParams[].
  5. Save — Validate and write with library.BlockPolicy.save().

API

policyData = struct();
policyData.policyMode = 'approved_blocks_only';
policyData.fallbackToBuiltins = false;
% Excluded — agent will never place these blocks
policyData.blockedBlocks = struct('referenceBlock', 'LegacyLib/OldCtrl', 'reason', 'Superseded');
% Protected params — agent won't modify these values
policyData.blockRules = struct('referenceBlock', 'Lib/SpeedCtrl', ...
    'protectedParams', {{'Kp', 'Ki', 'Kd'}});

library.BlockPolicy.save(projectRoot, policyData);

For defaults (no restrictions):

policyData = library.BlockPolicy.defaults();
library.BlockPolicy.save(projectRoot, policyData);

Schema

{
  "schemaVersion": 1,
  "policyMode": "approved_blocks_only | prefer_customer_libraries",
  "fallbackToBuiltins": false,
  "blockedBlocks": [
    { "referenceBlock": "LegacyLib/OldController", "reason": "Superseded" }
  ],
  "blockRules": [
    { "referenceBlock": "Lib/SpeedController", "protectedParams": ["Kp", "Ki", "Kd", "SampleTime"] }
  ]
}

Validation Rules

  • policyMode: must be prefer_customer_libraries or approved_blocks_only
  • approved_blocks_only + fallbackToBuiltins: true → rejected (contradictory)
  • protectedParams must be a non-empty array of strings
  • Malformed policy → error (never silently ignored)

Updating an Existing Policy

When .satk/block-policy.json already exists:

  1. Load with library.BlockPolicy.loadRaw(projectRoot, libConfig)
  2. Summarize current state — do NOT re-run the full wizard
  3. Ask what to change, apply to existing struct, save

Common updates: exclude a block, mark params as off-limits, change mode, remove an entry.

Guardrails

  • Never write block-policy.json without user confirmation
  • Always validate before saving (library.BlockPolicy.validate(policyData))
  • If user provides a block name without the full library path, look it up in the KG to resolve the referenceBlock

Copyright 2026 The MathWorks, Inc.


レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

Author or upgrade Model Advisor checks for Simulink and System Composer models. Covers the full lifecycle: guideline authoring, check specification, Model Advisor check implementation, and qualification testing. Use when creating new checks (edit-time, standard batch, config-parameter, auto-fix), converting legacy StyleOne/StyleTwo/StyleThree checks to modern DetailStyle, creating a guideline for modeling, enforcing a modeling rule, or testing/qualifying a check. Triggers on any modeling constraint (e.g., "blocks shall...", "signals must match...", "parameters shall be set to...").

日本語の概要は準備中です。原文の説明を表示しています。

matlab/simulink-agentic-toolkit1,2152026年10月8日 更新

Synthesize new waveforms from scratch for Simulink inports using createInputDataset. Use ONLY when the user asks to generate, create, or synthesize signals (step, ramp, sine, chirp, pulse, noise) to populate a Dataset for External Inputs or Signal Editor. Covers timeseries and timetable formats with correct data type, interpolation, units, and dimensions. Also covers function-call and trigger inport timing setup. Do NOT use when the user wants to load, import, or read existing data from files (MAT, CSV, spreadsheet) — even if that data will be used as model input. Do NOT use for running simulations or plotting outputs.

日本語の概要は準備中です。原文の説明を表示しています。

matlab/simulink-agentic-toolkit1,2152026年10月8日 更新

Common steps for building multi-layer system architecture models using System Composer. Use when implementing architecture models or when interacting with interface dictionaries, allocation sets, stereotypes, and requirements for architecture components.

日本語の概要は準備中です。原文の説明を表示しています。

matlab/simulink-agentic-toolkit1,2152026年10月8日 更新

Builds and edits Simulink, System Composer, Stateflow, and Simscape models. Use when modifying model structure, parameters, ports, connections, or Stateflow chart internals.

日本語の概要は準備中です。原文の説明を表示しています。

matlab/simulink-agentic-toolkit1,2152026年10月8日 更新

Use this skill when the user asks to check Simulink model compliance against a standard (MISRA, MAB, JMAAB, ISO, DO, IEC, EN, CERT C/CWE, AUTOSAR, Simulink Code Inspector (SLCI)), wants to run Model Advisor checks, or needs a compliance report with fix suggestions. For JMAAB/MAB, supplement deterministic checks with agentic review of uncheckable guidelines.

日本語の概要は準備中です。原文の説明を表示しています。

matlab/simulink-agentic-toolkit1,2152026年10月8日 更新

Import data into the Simulation Data Inspector (SDI) from MAT, CSV, or Excel files, from workspace variables, or from a Simulink simulation. Use when the user wants to view a logged file in SDI, load a bench-test log, or verify what a just-completed `Simulink.sdi.createRun` or `sim(model)` produced. Covers the `'file'`, `'vars'`, and `'namevalue'` sources of `createRun`, the auto-populate behavior after `sim()`, and post-import verification. Not for comparing existing runs (use `Simulink.sdi.compareRuns`); not for streaming data live during a running simulation (use `Simulink.sdi.createRunOrAddToStreamedRun` — a separate API); and not for authoring Gherkin or Simulink Test test cases, assertions, or regression tests (use `testing-simulink-models`). Do not activate on test-authoring or verification prompts even when no test-authoring skill is available — say so and stop.

日本語の概要は準備中です。原文の説明を表示しています。

matlab/simulink-agentic-toolkit1,2152026年10月8日 更新

matlab のスキルをすべて見る

このスキルの問題を報告する