@moda-ai/cli 1.28.0 → 1.28.1

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/dist/cli.js CHANGED
@@ -933,9 +933,11 @@ function materializePacketCandidates(packet, fixId, human) {
933
933
  const summaryParts = [];
934
934
  const tool = packet.candidate_tool;
935
935
  const skill = packet.candidate_skill;
936
+ const skillEdit = packet.candidate_skill_edit;
936
937
  const hasTool = typeof tool?.proposed_description === "string" && tool.proposed_description !== "";
937
938
  const hasSkill = typeof skill?.skill_md === "string" && skill.skill_md !== "";
938
- if (!hasTool && !hasSkill) {
939
+ const hasSkillEdit = typeof skillEdit?.proposed_skill_md === "string" && skillEdit.proposed_skill_md !== "";
940
+ if (!hasTool && !hasSkill && !hasSkillEdit) {
939
941
  return { findings, artifacts, warnings, nextCommands, summarySuffix: "" };
940
942
  }
941
943
  const rawRef = typeof packet.short_ref === "string" && packet.short_ref.trim() ? packet.short_ref : fixId;
@@ -1014,6 +1016,34 @@ function materializePacketCandidates(packet, fixId, human) {
1014
1016
  w(` moda fix mark-applied ${fixId} --note="installed skill ${skillName}"`);
1015
1017
  }
1016
1018
  }
1019
+ if (hasSkillEdit && skillEdit) {
1020
+ const skillKey = typeof skillEdit.skill_key === "string" && skillEdit.skill_key ? skillEdit.skill_key : typeof skillEdit.skill_name === "string" && skillEdit.skill_name ? skillEdit.skill_name : "moda-skill";
1021
+ const changeSummary = typeof skillEdit.change_summary === "string" ? skillEdit.change_summary : "";
1022
+ const currentPath = writeCandidateFile("SKILL.current.md", typeof skillEdit.current_skill_md === "string" ? skillEdit.current_skill_md : "", "fix_skill_edit_current", `Current SKILL.md of your synced skill '${skillKey}' — the diff base.`);
1023
+ const proposedPath = writeCandidateFile("SKILL.proposed.md", skillEdit.proposed_skill_md ?? "", "fix_skill_edit_proposed", `Proposed SKILL.md for '${skillKey}' (minimal edit) — apply it to the existing skill in your repo, then \`moda fix mark-applied ${fixId}\`.`);
1024
+ findings.push({
1025
+ id: "fix:candidate_skill_edit",
1026
+ title: `skill '${skillKey}' edit proposed${changeSummary ? `: ${changeSummary}` : " (minimal delta to the existing skill)"}`,
1027
+ status: "proposed",
1028
+ severity: "info",
1029
+ description: `This amends the EXISTING synced skill '${skillKey}' — a minimal delta, not a new skill. Apply the proposed SKILL.md in your repo, then confirm with \`moda fix mark-applied ${fixId}\`.`
1030
+ });
1031
+ summaryParts.push(`Includes a skill-edit candidate amending existing skill '${skillKey}'.`);
1032
+ if (human) {
1033
+ w("");
1034
+ w(`Skill-edit candidate — amends existing skill '${skillKey}'`);
1035
+ if (changeSummary)
1036
+ block("change summary", changeSummary);
1037
+ if (currentPath)
1038
+ w(` current SKILL.md written to ${currentPath}`);
1039
+ if (proposedPath)
1040
+ w(` proposed SKILL.md written to ${proposedPath}`);
1041
+ if (currentPath && proposedPath)
1042
+ w(` diff: diff ${currentPath} ${proposedPath}`);
1043
+ w(` apply the edit to the existing skill in your repo, then confirm:`);
1044
+ w(` moda fix mark-applied ${fixId} --note="amended skill ${skillKey}"`);
1045
+ }
1046
+ }
1017
1047
  nextCommands.push({
1018
1048
  command: `moda fix mark-applied ${fixId} --note="where/how you applied it"`,
1019
1049
  purpose: "Confirm you applied the candidate in your own stack (no PR) — flips the fix to SHIPPED and starts recurrence monitoring.",
@@ -1087,7 +1117,7 @@ function nextCommandsFor(fix) {
1087
1117
  mutability: "write",
1088
1118
  requires_approval: true
1089
1119
  };
1090
- const skillGatePending = fix.fixType === "SKILL" && fix.candidateRef?.kind === "skill" && !fix.candidateRef?.skillId;
1120
+ const skillGatePending = fix.fixType === "SKILL" && (fix.candidateRef?.kind === "skill_edit" || fix.candidateRef?.kind === "skill" && !fix.candidateRef?.skillId);
1091
1121
  switch (fix.status) {
1092
1122
  case "VERIFIED":
1093
1123
  if (isArtifactFix(fix)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moda-ai/cli",
3
- "version": "1.28.0",
3
+ "version": "1.28.1",
4
4
  "description": "CLI for Moda - AI agent analytics and observability",
5
5
  "type": "module",
6
6
  "bin": {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "schema_version": "moda.skill_index.v1",
3
- "bundled_at": "2026-08-19T21:29:46.133Z",
4
- "cli_version": "1.28.0",
3
+ "bundled_at": "2026-08-19T22:54:45.735Z",
4
+ "cli_version": "1.28.1",
5
5
  "skills": [
6
6
  {
7
7
  "id": "integration-node-anthropic",