examples-imports
Use for demonstrates always-loaded policy, on-demand procedure imports, section narrowing, and nested import requirements. Preserves evidence with SkillSpec routes, forbids, dependencies, traces, and token-savings reports
modiqo · 已有 AI 审核记录
安装与使用
运行命令前先阅读来源与依赖说明。复制命令不会自动安装或执行。
npx skills add modiqo/skillspec --skill examples-imports技能说明
name: examples-imports description: "Use for demonstrates always-loaded policy, on-demand procedure imports, section narrowing, and nested import requirements. Preserves evidence with SkillSpec routes, forbids, dependencies, traces, and token-savings reports"
imports example
Demonstrates always-loaded policy, on-demand procedure imports, section narrowing, and nested import requirements.
This skill is a thin loader for the colocated skill.spec.yml. The spec is the source of truth for routes, rules, dependencies, imports, resources, recipes, tests, and trace requirements. Do not treat the spec as background prose; treat it as the execution contract for this task.
Runtime Contract
-
Load
./skill.spec.ymlfrom this skill folder before taking task actions. -
When the
skillspecCLI is available and the spec shape is unfamiliar, runskillspec sensemake ./skill.spec.yml --view indexto learn the section roles, counts, query handles, and navigation grammar without dumping the full YAML. -
Then create the ordered phase plan and current-route action checklist:
skillspec plan ./skill.spec.yml --input='<user task>' --trace-dir "${PWD}/.skillspec/traces" skillspec act ./skill.spec.yml --input='<user task>' --run <run_dir> --phase <phase-id> -
Strip skill invocation prefixes such as
/my-skill,$my-skill, or/durable-executor-specbefore passing--input. -
Preserve the emitted trace
run_dir. -
Read the full phase plan and action checklist before using tools. Treat them as the active execution SOP, not as advice. The
PHASE TOOL BOUNDARY - HARDsection is the permission boundary for the next action. -
For each execution phase, run
skillspec act ./skill.spec.yml --input='<user task>' --run <run_dir> --phase <phase-id>before acting, record phase progress in<run_dir>/execution.jsonl, then runskillspec progress show ./skill.spec.yml --run <run_dir>to see completed, current, blocked, and remaining phases. -
Pull active details with
skillspec query ./skill.spec.yml <handle> --view summaryand relationship edges withskillspec refs ./skill.spec.yml <handle> --view summary. Prefer precise handles such asrule:<id>,rule:<id>.forbid,command:<id>.requires, andstate:<id>.nextover reading the whole spec. -
Before every substrate/tool call, apply the phase tool boundary and checklist allow/deny questions. Any unlisted tool, data source, execution substrate, provider, adapter, CLI, browser mode, API, or skill requires explicit user permission before use. The selected route and matched rules override lower-level skill defaults and generic tool preferences.
-
When the CLI is available after a trace exists, run
skillspec trace align ./skill.spec.yml --decision-trace <run_dir>and, when structured action evidence exists, add--execution-trace <run_dir>/execution.jsonl. The command writes<run_dir>/alignment.json; report the alignment status, meaning, model layers, evidence gaps, user-facing proof rows, summary, and trace path. -
If
skillspec plan,skillspec act, orskillspec progressis unavailable, fall back toskillspec decide, then manually construct the same ordered phase checklist and progress notes before using tools. If the CLI is unavailable, readskill.spec.ymldirectly and apply the same contract manually. Do not expand this loader into a second source of truth.
Authoring And Revision Contract
When importing, creating, revising, or extending this SkillSpec-backed skill, use the embedded grammar teacher before editing skill.spec.yml:
skillspec grammar sensemake --view index
skillspec grammar sensemake --view porting
skillspec grammar checklist --for import-skill
- Treat the checklist as the review gate for semantic edits: activation, routes, rules, elicitations, imports/resources, commands/deps, procedures, tests, proof, and contract quality.
- Fill or update a coverage matrix with
prose_span | obligation | skillspec_construct | confidence | status | review_notebefore installing or releasing a changed skill. - Use
skillspec grammar schema --jsonwhen a harness needs the exact embedded JSON schema. - Do not patch YAML by memory when the binary can teach the current grammar. Run the grammar commands again after CLI upgrades or when a spec shape is unfamiliar.
Durable Handoff Contract
This skill participates in agent-mediated durable execution. There is no runtime handoff engine: the agent reads the active SkillSpec contracts, carries the handoff packet in context, and preserves the declared evidence.
- If a durable handoff packet is present, preserve its
workspace,trace_dir,return_to,branch_id, andexecution_policyfields. - If no durable handoff packet is present and the task asks for remembered evidence, future recall, reuse, trace, alignment, or durable execution, route through
durable-executorfirst unless the user explicitly requests direct/no-rote execution. - If
durable_context.activeis true, do not route the whole task back todurable-executor; usedurable-executoronly as the execution substrate and then return toreturn_to. - This skill owns its domain interpretation and validation.
durable-executorowns workspace, trace, evidence, command substrate, final alignment, token-savings, and recall/crystallization closure when it initiated the handoff. - Any CLI, shell command, local process, package command, API fallback, or provider command must use the durable execution substrate, normally a rote adapter or
rote exec --, unless the active spec or user explicitly allows direct execution. - On completion, emit a return packet with status, selected route, skill metadata, artifacts, evidence handles, blockers, and trace paths, then hand back to
return_tofor final closure. - For parallel work, keep one top-level workspace but use branch-scoped
branch_id, trace paths, evidence labels, and artifact directories.