skillscript-runtime 0.33.0 → 0.35.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +28 -0
- package/README.md +5 -4
- package/dist/bootstrap-from-env.d.ts.map +1 -1
- package/dist/bootstrap-from-env.js +2 -0
- package/dist/bootstrap-from-env.js.map +1 -1
- package/dist/bootstrap.d.ts +9 -0
- package/dist/bootstrap.d.ts.map +1 -1
- package/dist/bootstrap.js +4 -0
- package/dist/bootstrap.js.map +1 -1
- package/dist/cli.js +6 -0
- package/dist/cli.js.map +1 -1
- package/dist/composition.d.ts +4 -0
- package/dist/composition.d.ts.map +1 -1
- package/dist/composition.js +12 -0
- package/dist/composition.js.map +1 -1
- package/dist/connectors/index.d.ts +1 -1
- package/dist/connectors/index.d.ts.map +1 -1
- package/dist/connectors/index.js.map +1 -1
- package/dist/connectors/registry.d.ts.map +1 -1
- package/dist/connectors/registry.js +11 -0
- package/dist/connectors/registry.js.map +1 -1
- package/dist/connectors/types.d.ts +36 -0
- package/dist/connectors/types.d.ts.map +1 -1
- package/dist/connectors/types.js.map +1 -1
- package/dist/errors.d.ts +64 -0
- package/dist/errors.d.ts.map +1 -1
- package/dist/errors.js +60 -0
- package/dist/errors.js.map +1 -1
- package/dist/help-content.d.ts +1 -1
- package/dist/help-content.d.ts.map +1 -1
- package/dist/help-content.js +5 -1
- package/dist/help-content.js.map +1 -1
- package/dist/lint.d.ts.map +1 -1
- package/dist/lint.js +38 -0
- package/dist/lint.js.map +1 -1
- package/dist/mcp-server.d.ts +8 -0
- package/dist/mcp-server.d.ts.map +1 -1
- package/dist/mcp-server.js +8 -0
- package/dist/mcp-server.js.map +1 -1
- package/dist/parser.d.ts +11 -0
- package/dist/parser.d.ts.map +1 -1
- package/dist/parser.js +17 -0
- package/dist/parser.js.map +1 -1
- package/dist/runtime-config.d.ts +8 -0
- package/dist/runtime-config.d.ts.map +1 -1
- package/dist/runtime-config.js +8 -0
- package/dist/runtime-config.js.map +1 -1
- package/dist/runtime-env-resolver.d.ts +2 -0
- package/dist/runtime-env-resolver.d.ts.map +1 -1
- package/dist/runtime-env-resolver.js +8 -0
- package/dist/runtime-env-resolver.js.map +1 -1
- package/dist/runtime.d.ts +86 -0
- package/dist/runtime.d.ts.map +1 -1
- package/dist/runtime.js +325 -76
- package/dist/runtime.js.map +1 -1
- package/dist/scheduler.d.ts +3 -0
- package/dist/scheduler.d.ts.map +1 -1
- package/dist/scheduler.js +3 -0
- package/dist/scheduler.js.map +1 -1
- package/dist/trace.d.ts +22 -2
- package/dist/trace.d.ts.map +1 -1
- package/dist/trace.js +7 -1
- package/dist/trace.js.map +1 -1
- package/docs/adopter-playbook.md +31 -0
- package/docs/connector-contract-reference.md +38 -0
- package/docs/language-reference.md +95 -46
- package/examples/connectors/README.md +2 -2
- package/examples/connectors/RestConnector/.env.example +19 -0
- package/examples/connectors/RestConnector/README.md +109 -0
- package/examples/connectors/RestConnector/RestConnector.ts +326 -0
- package/examples/skillscripts/classify-support-ticket.skill.provenance.json +1 -1
- package/examples/skillscripts/data-store-roundtrip.skill.provenance.json +1 -1
- package/examples/skillscripts/doc-qa-with-citations.skill.provenance.json +1 -1
- package/examples/skillscripts/feedback-sentiment-scan.skill.provenance.json +1 -1
- package/examples/skillscripts/hello-world.skill.provenance.json +1 -1
- package/examples/skillscripts/morning-brief.skill.provenance.json +1 -1
- package/examples/skillscripts/queue-length-monitor.skill.provenance.json +1 -1
- package/examples/skillscripts/service-health-watch.skill.provenance.json +1 -1
- package/examples/skillscripts/skill-store-roundtrip.skill.provenance.json +1 -1
- package/examples/skillscripts/youtrack-morning-sweep.skill.provenance.json +1 -1
- package/package.json +1 -1
- package/scaffold/.env.example +9 -0
package/dist/lint.js
CHANGED
|
@@ -3684,6 +3684,43 @@ const ADDRESS_ROUTED_WAKE_INFO = {
|
|
|
3684
3684
|
return findings;
|
|
3685
3685
|
},
|
|
3686
3686
|
};
|
|
3687
|
+
/**
|
|
3688
|
+
* Adoption nudge for the deadlines feature (Perry spec de11dcc5). A skill that
|
|
3689
|
+
* performs an external/effectful dispatch (`$` / `shell` / `notify`) but declares
|
|
3690
|
+
* no `# Deadline:` has no total wall-clock bound — the run and everything it
|
|
3691
|
+
* composes can hang unboundedly on one slow dispatch. Opt-in feature, so this is
|
|
3692
|
+
* a tier-3 advisory (not op-count-based: a single `$ llm` is enough to be
|
|
3693
|
+
* unbounded). Predicate: ≥1 unbounded dispatch AND no `# Deadline:`.
|
|
3694
|
+
*/
|
|
3695
|
+
const UNBOUNDED_NO_DEADLINE = {
|
|
3696
|
+
id: "unbounded-no-deadline",
|
|
3697
|
+
severity: "info",
|
|
3698
|
+
description: "A skill with an external/effectful dispatch ($, shell, notify) but no `# Deadline:` has no total wall-clock bound; the run (and its execute_skill tree) can hang on a slow dispatch.",
|
|
3699
|
+
remediation: "Add a `# Deadline: N` header (seconds) to bound the whole run + everything it composes. Opt-in — without it the skill keeps per-op timeouts only, which don't bound the total.",
|
|
3700
|
+
check: (ctx) => {
|
|
3701
|
+
if (ctx.parsed.deadline !== null)
|
|
3702
|
+
return [];
|
|
3703
|
+
let firstTarget;
|
|
3704
|
+
for (const [targetName, target] of ctx.parsed.targets) {
|
|
3705
|
+
const collect = (op) => {
|
|
3706
|
+
if (firstTarget === undefined && (op.kind === "$" || op.kind === "shell" || op.kind === "notify")) {
|
|
3707
|
+
firstTarget = targetName;
|
|
3708
|
+
}
|
|
3709
|
+
};
|
|
3710
|
+
walkOps(target.ops, collect);
|
|
3711
|
+
if (target.elseBlock !== undefined)
|
|
3712
|
+
walkOps(target.elseBlock, collect);
|
|
3713
|
+
}
|
|
3714
|
+
if (firstTarget === undefined)
|
|
3715
|
+
return [];
|
|
3716
|
+
return [{
|
|
3717
|
+
rule: "unbounded-no-deadline",
|
|
3718
|
+
severity: "info",
|
|
3719
|
+
message: `Skill performs an external/effectful dispatch (target '${firstTarget}') but declares no \`# Deadline:\` — the run has no total wall-clock bound.`,
|
|
3720
|
+
block: firstTarget,
|
|
3721
|
+
}];
|
|
3722
|
+
},
|
|
3723
|
+
};
|
|
3687
3724
|
const RULES = [
|
|
3688
3725
|
// Tier-1 (error)
|
|
3689
3726
|
PARSE_ERROR,
|
|
@@ -3766,6 +3803,7 @@ const RULES = [
|
|
|
3766
3803
|
BODY_TEMPLATE_DETECTED,
|
|
3767
3804
|
EMIT_WITH_TEMPLATE,
|
|
3768
3805
|
REMOTE_RESULT_NEEDS_PARSE,
|
|
3806
|
+
UNBOUNDED_NO_DEADLINE,
|
|
3769
3807
|
];
|
|
3770
3808
|
/** Read-only view of the rule registry — for tooling that introspects v1 rules. */
|
|
3771
3809
|
export function listRules() {
|