@fro.bot/systematic 1.17.0 → 1.17.2

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.
Files changed (2) hide show
  1. package/dist/index.js +17 -7
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -197,8 +197,15 @@ function loadCommandAsConfig(commandInfo) {
197
197
  const { body } = parseFrontmatter(converted);
198
198
  const cleanName = commandInfo.name.replace(/^\//, "");
199
199
  const baseDescription = description || `${name || cleanName} command`;
200
+ const wrappedTemplate = `<command-instruction>
201
+ ${body.trim()}
202
+ </command-instruction>
203
+
204
+ <user-request>
205
+ $ARGUMENTS
206
+ </user-request>`;
200
207
  const config = {
201
- template: body.trim(),
208
+ template: wrappedTemplate,
202
209
  description: `(Systematic) ${baseDescription}`
203
210
  };
204
211
  if (agent !== undefined)
@@ -341,11 +348,14 @@ function discoverSkillFiles(dir, limit = 10) {
341
348
  }
342
349
  function createSkillTool(options) {
343
350
  const { bundledSkillsDir, disabledSkills } = options;
344
- const getSystematicSkills = () => {
345
- return findSkillsInDir(bundledSkillsDir).filter((s) => !disabledSkills.includes(s.name)).map((skillInfo) => loadSkill(skillInfo)).filter((s) => s !== null).filter((s) => s.disableModelInvocation !== true).sort((a, b) => a.name.localeCompare(b.name));
351
+ const getAllSkills = () => {
352
+ return findSkillsInDir(bundledSkillsDir).filter((s) => !disabledSkills.includes(s.name)).map((skillInfo) => loadSkill(skillInfo)).filter((s) => s !== null).sort((a, b) => a.name.localeCompare(b.name));
353
+ };
354
+ const getDiscoverableSkills = () => {
355
+ return getAllSkills().filter((s) => s.disableModelInvocation !== true);
346
356
  };
347
357
  const buildDescription = () => {
348
- const skills = getSystematicSkills();
358
+ const skills = getDiscoverableSkills();
349
359
  if (skills.length === 0) {
350
360
  return "Load a skill to get detailed instructions for a specific task. No skills are currently available.";
351
361
  }
@@ -373,7 +383,7 @@ function createSkillTool(options) {
373
383
  `);
374
384
  };
375
385
  const buildParameterHint = () => {
376
- const skills = getSystematicSkills();
386
+ const skills = getDiscoverableSkills();
377
387
  const examples = skills.slice(0, 3).map((s) => `'systematic:${s.name}'`).join(", ");
378
388
  const hint = examples.length > 0 ? ` (e.g., ${examples}, ...)` : "";
379
389
  return `The name of the skill from available_skills${hint}`;
@@ -398,10 +408,10 @@ function createSkillTool(options) {
398
408
  async execute(args, context) {
399
409
  const requestedName = args.name;
400
410
  const normalizedName = requestedName.startsWith("systematic:") ? requestedName.slice("systematic:".length) : requestedName;
401
- const skills = getSystematicSkills();
411
+ const skills = getAllSkills();
402
412
  const matchedSkill = skills.find((s) => s.name === normalizedName);
403
413
  if (!matchedSkill) {
404
- const availableSystematic = skills.map((s) => s.prefixedName);
414
+ const availableSystematic = getDiscoverableSkills().map((s) => s.prefixedName);
405
415
  throw new Error(`Skill "${requestedName}" not found. Available systematic skills: ${availableSystematic.join(", ")}`);
406
416
  }
407
417
  const body = extractSkillBody(matchedSkill.wrappedTemplate);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fro.bot/systematic",
3
- "version": "1.17.0",
3
+ "version": "1.17.2",
4
4
  "description": "Structured engineering workflows for OpenCode",
5
5
  "type": "module",
6
6
  "homepage": "https://fro.bot/systematic",