@bendyline/gezel-mcp 1.2.11 → 1.2.12

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/harness.js CHANGED
@@ -2465,7 +2465,8 @@ ${doc.markdown}`);
2465
2465
  aspectRatio: z2.enum(IMAGE_ASPECT_RATIOS).optional(),
2466
2466
  quality: z2.enum(IMAGE_QUALITIES).optional().describe("'draft', 'standard' (default) or 'high'."),
2467
2467
  negativePrompt: z2.string().max(2e3).optional().describe("Things to keep out of the image."),
2468
- inputImages: z2.array(z2.string().min(1)).max(4).optional().describe("Images to edit or combine: absolute paths, or paths relative to this folder.")
2468
+ inputImages: z2.array(z2.string().min(1)).max(4).optional().describe("Images to edit or combine: absolute paths, or paths relative to this folder."),
2469
+ style: z2.string().max(100).optional().describe("A look to draw in, by name.")
2469
2470
  }
2470
2471
  },
2471
2472
  async (args) => guarded(async () => {
@@ -2490,7 +2491,8 @@ ${doc.markdown}`);
2490
2491
  ...args.aspectRatio ? { aspectRatio: args.aspectRatio } : {},
2491
2492
  ...args.quality ? { quality: args.quality } : {},
2492
2493
  ...args.negativePrompt ? { negativePrompt: args.negativePrompt } : {},
2493
- ...inputs.length > 0 ? { inputImages: inputs } : {}
2494
+ ...inputs.length > 0 ? { inputImages: inputs } : {},
2495
+ ...args.style ? { style: args.style } : {}
2494
2496
  })
2495
2497
  );
2496
2498
  const artifactsDir = binding.info?.artifactsDir;
@@ -2499,9 +2501,10 @@ ${doc.markdown}`);
2499
2501
  if (res.b64Png) content.push({ type: "image", data: res.b64Png, mimeType: "image/png" });
2500
2502
  const skipped = res.meta.img2imgSkippedReason ? `This image engine can't edit images (${res.meta.img2imgSkippedReason}), so it ignored inputImages and made a new image from the prompt alone. To change an image, describe the whole picture you want. ` : "";
2501
2503
  const settings = res.meta.settingsNotes?.length ? `Image settings: ${res.meta.settingsNotes.join(" ")} ` : "";
2504
+ const styles = res.styles?.length ? ` Styles this model has: ${res.styles.map((s) => s.name).join(", ")}.` : "";
2502
2505
  content.push({
2503
2506
  type: "text",
2504
- text: `${skipped}${settings}Saved to ${saved} (${res.meta.widthPx}x${res.meta.heightPx}, ${res.meta.model}). Copy it into the folder with your own file tools if it belongs there.`
2507
+ text: `${skipped}${settings}Saved to ${saved} (${res.meta.widthPx}x${res.meta.heightPx}, ${res.meta.model}). Copy it into the folder with your own file tools if it belongs there.${styles}`
2505
2508
  });
2506
2509
  return { content };
2507
2510
  })
package/dist/server.js CHANGED
@@ -82,8 +82,10 @@ import {
82
82
  askUserQuestionText,
83
83
  assertCraftbookGraph,
84
84
  asyncHandoffReleaseInstruction,
85
+ binaryDocumentWriteRefusalText,
85
86
  coerceDeliverableKind,
86
87
  composeCraftbookLaunch,
88
+ craftbookCheckup,
87
89
  craftbookDocFormatFromEnv,
88
90
  createTaskText,
89
91
  crewMemberNamedIn,
@@ -96,6 +98,7 @@ import {
96
98
  getTaskText,
97
99
  inferDeliverableKind,
98
100
  inferScriptScope,
101
+ isBinaryDocumentPath as isBinaryDocumentPath3,
99
102
  isReservedShadowArtifactPath,
100
103
  isTrustedConstrainedToolset,
101
104
  listArtifactsText,
@@ -122,7 +125,7 @@ import {
122
125
  searchResultText,
123
126
  stepCheckedArtifactPaths,
124
127
  stepInsertionIndex,
125
- stepOwnerGezelId,
128
+ stepOwnerGezelId as stepOwnerGezelId2,
126
129
  taskOwnedPrefixes,
127
130
  taskPersonNoun,
128
131
  taskScopedWriteDeniedMessage,
@@ -2493,6 +2496,28 @@ function createEntityResolvers(deps) {
2493
2496
  return { resolveProjectId: resolveProjectId2, resolveGezelId: resolveGezelId2, availableGezelsHint: availableGezelsHint2, parseRef: parseRef2 };
2494
2497
  }
2495
2498
 
2499
+ // src/entry-step-start.ts
2500
+ import { isOwnerStep, stepOwnerGezelId } from "@bendyline/gezel";
2501
+ function entryStepStart(task) {
2502
+ const step = task.craftbook.steps.find((candidate) => candidate.id === task.activeStepId);
2503
+ const dispatched = {
2504
+ text: `Active step ${task.activeStepId ?? "(none)"} was dispatched to the recipe-selected specialist.`,
2505
+ underway: true
2506
+ };
2507
+ if (task.status !== "active" || !step) return dispatched;
2508
+ if (isOwnerStep(step)) {
2509
+ return {
2510
+ text: `Its first step "${step.name}" is the person's own step, so it waits for them.`,
2511
+ underway: false
2512
+ };
2513
+ }
2514
+ if (stepOwnerGezelId(task, step)) return dispatched;
2515
+ return {
2516
+ text: `Nobody was assigned to start its first step "${step.name}" (${step.id}): the step names no suggestedRole and the task belongs to the person, so it will sit idle. Assign it now with assign_task({ ref: "${task.ref}", assignee: "<a gezel's name or a role>" }), which starts the step. Do not invoke the recipe again. If you wrote this recipe, give each step a suggestedRole so the next run starts on its own.`,
2517
+ underway: false
2518
+ };
2519
+ }
2520
+
2496
2521
  // src/github-tools.ts
2497
2522
  import { prioritizePullsForCurrentBranch } from "@bendyline/gezel";
2498
2523
  import { z as z6 } from "zod";
@@ -4935,7 +4960,7 @@ async function staleStepMutationResult() {
4935
4960
  sessionStepCompletion = activeStep.advanceWhen ? "automatic" : "manual";
4936
4961
  sessionStepCheckedArtifacts = stepCheckedArtifactPaths(activeStep);
4937
4962
  }
4938
- const owner = activeStep ? stepOwnerGezelId(task, activeStep) : void 0;
4963
+ const owner = activeStep ? stepOwnerGezelId2(task, activeStep) : void 0;
4939
4964
  activeStepOwnedBySession = !!gezelId && owner === gezelId;
4940
4965
  } catch {
4941
4966
  return null;
@@ -6104,6 +6129,11 @@ function rasterImageWriteRefusal(path) {
6104
6129
  isError: true
6105
6130
  };
6106
6131
  }
6132
+ function binaryDocumentWriteRefusal(path, drawer) {
6133
+ if (!isBinaryDocumentPath3(path)) return null;
6134
+ const hasTool = (name) => name === "copy_artifact_to_workspace" ? toolIsAuthorizedForThisSession(name) : authorizedToolNames?.has(canonicalToolName(name)) === true;
6135
+ return errorResult(binaryDocumentWriteRefusalText(path, { drawer, hasTool }));
6136
+ }
6107
6137
  server.tool(
6108
6138
  "write_file",
6109
6139
  GEZEL_TOOL_DESCRIPTIONS2.write_file,
@@ -6121,7 +6151,7 @@ ${JSON.stringify(drawerPath)} is this task's working folder in the artifacts dra
6121
6151
  content: [{ type: "text", text: notice }, ...written.content]
6122
6152
  };
6123
6153
  }
6124
- const raster = rasterImageWriteRefusal(path);
6154
+ const raster = rasterImageWriteRefusal(path) ?? binaryDocumentWriteRefusal(path, "workspace");
6125
6155
  if (raster) return raster;
6126
6156
  const scoped = await taskScopedWriteRefusal(path, "workspace");
6127
6157
  if (scoped) return scoped;
@@ -6241,7 +6271,7 @@ server.tool(
6241
6271
  async ({ path, content, create }) => {
6242
6272
  const stale = await staleStepMutationResult();
6243
6273
  if (stale) return stale;
6244
- const raster = rasterImageWriteRefusal(path);
6274
+ const raster = rasterImageWriteRefusal(path) ?? binaryDocumentWriteRefusal(path, "workspace");
6245
6275
  if (raster) return raster;
6246
6276
  const scoped = await taskScopedWriteRefusal(path, "workspace");
6247
6277
  if (scoped) return scoped;
@@ -7609,7 +7639,7 @@ async function writeArtifactToolCall({
7609
7639
  }) {
7610
7640
  const stale = await staleStepMutationResult();
7611
7641
  if (stale) return stale;
7612
- const raster = rasterImageWriteRefusal(path);
7642
+ const raster = rasterImageWriteRefusal(path) ?? binaryDocumentWriteRefusal(path, "artifacts");
7613
7643
  if (raster) return raster;
7614
7644
  const scoped = await taskScopedWriteRefusal(path, "artifacts");
7615
7645
  if (scoped) return scoped;
@@ -7722,8 +7752,7 @@ async function writeArtifactToolCall({
7722
7752
  };
7723
7753
  }
7724
7754
  }
7725
- const stored = clean.endsWith(".md") ? normalizeMarkdown(content) : content;
7726
- await api.writeProjectArtifact(projectId, clean, stored, {
7755
+ await api.writeProjectArtifact(projectId, clean, content, {
7727
7756
  ...gezelId ? { gezelId } : {},
7728
7757
  ...sessionId ? { sessionId } : {}
7729
7758
  });
@@ -8231,11 +8260,18 @@ function craftbookSetupRequiredText(craftbookId, missing) {
8231
8260
  }).join(", ");
8232
8261
  return `SETUP REQUIRED for craftbook "${craftbookId}": install/configure ${needs} from the project's Craftbooks/Commands setup before invoking it. Do not create a substitute task, hand-write replacement steps, or silently change the requested output format.`;
8233
8262
  }
8234
- async function autoInstallTrustedCraftbookToolsets(project, requirements) {
8263
+ async function autoInstallTrustedCraftbookToolsets(project, requirements, missing) {
8235
8264
  const installed = [];
8236
8265
  const scope = { kind: "project", projectId: project };
8237
8266
  const roster = await api.listInstalledToolsets(scope);
8267
+ const machineWide = new Set(
8268
+ (await api.listInstalledToolsets({ kind: "system" }).catch(() => ({ toolsets: [] }))).toolsets.map((entry) => entry.toolsetId)
8269
+ );
8270
+ const missingIds = new Set(missing.map((need) => need.toolsetId));
8238
8271
  for (const need of requirements) {
8272
+ if (machineWide.has(need.toolsetId)) continue;
8273
+ const projectCopy = roster.toolsets.some((entry) => entry.toolsetId === need.toolsetId);
8274
+ if (!projectCopy && !missingIds.has(need.toolsetId)) continue;
8239
8275
  const detail = await api.getCatalogItem("toolset", need.toolsetId, {
8240
8276
  ...need.sourceId ? { source: need.sourceId } : {}
8241
8277
  });
@@ -8348,7 +8384,8 @@ async function launchCraftbookTask(args) {
8348
8384
  const declaredRequirements = declaredCraftbook?.manifest.kind === "craftbook-template" ? declaredCraftbook.manifest.toolsets ?? missing : missing;
8349
8385
  const installed = await autoInstallTrustedCraftbookToolsets(
8350
8386
  args.project,
8351
- declaredRequirements.filter((need) => !need.optional)
8387
+ declaredRequirements.filter((need) => !need.optional),
8388
+ missing
8352
8389
  );
8353
8390
  if (installed.length > 0) {
8354
8391
  projectCraftbooks = await api.listProjectCraftbooks(args.project);
@@ -8688,6 +8725,7 @@ async function runInvokeCraftbook({
8688
8725
  }
8689
8726
  const created = launch.task;
8690
8727
  const stepCount = created.craftbook.steps.length;
8728
+ const start = entryStepStart(created);
8691
8729
  const installedText = launch.installed.length > 0 ? ` Installed or upgraded project toolset${launch.installed.length === 1 ? "" : "s"}: ${launch.installed.join(", ")}.` : "";
8692
8730
  const versionText = launch.kind === "created" && launch.ignoredVersion ? ` Version "${launch.ignoredVersion}" is not one this craftbook offers, so the latest ran.` : "";
8693
8731
  const idempotentText = launched.reused ? " This identical craftbook invocation already succeeded in the current root turn; reused its task instead of creating a duplicate." : "";
@@ -8706,7 +8744,7 @@ async function runInvokeCraftbook({
8706
8744
  }
8707
8745
  },
8708
8746
  {
8709
- text: `Invoked craftbook "${craftbookId}" \u2014 task ${created.ref} (${stepCount} step(s)). Active step ${created.activeStepId ?? "(none)"} was dispatched to the recipe-selected specialist.${installedText}${versionText}${idempotentText} Tell the person that ${taskPersonNoun(created)} is underway. ${PLAIN_WORDS_RELAY}`
8747
+ text: `Invoked craftbook "${craftbookId}" \u2014 task ${created.ref} (${stepCount} step(s)). ${start.text}${installedText}${versionText}${idempotentText}${start.underway ? ` Tell the person that ${taskPersonNoun(created)} is underway.` : ""} ${PLAIN_WORDS_RELAY}`
8710
8748
  }
8711
8749
  );
8712
8750
  } catch (err) {
@@ -8740,6 +8778,13 @@ async function runInvokeCraftbook({
8740
8778
  }
8741
8779
  }
8742
8780
  async function resolveCraftbookTarget(args) {
8781
+ const target = await resolveOptionalCraftbookTarget(args);
8782
+ if (target) return target;
8783
+ throw new Error(
8784
+ "no craftbook target: pass `craftbook` (a local template id) or `task` (a task ref), or run inside a craftbook-editing or task session."
8785
+ );
8786
+ }
8787
+ async function resolveOptionalCraftbookTarget(args) {
8743
8788
  if (args.task) {
8744
8789
  const parsed = await parseRef(args.task);
8745
8790
  const target = {
@@ -8761,9 +8806,7 @@ async function resolveCraftbookTarget(args) {
8761
8806
  const parsed = await parseRef(sessionTaskRef);
8762
8807
  return { kind: "task", projectId: parsed.projectId, num: parsed.num, ref: sessionTaskRef };
8763
8808
  }
8764
- throw new Error(
8765
- "no craftbook target: pass `craftbook` (a local template id) or `task` (a task ref), or run inside a craftbook-editing or task session."
8766
- );
8809
+ return null;
8767
8810
  }
8768
8811
  function describeTarget(t) {
8769
8812
  return t.kind === "task" ? `task ${t.ref}` : `craftbook ${t.id}`;
@@ -8848,14 +8891,17 @@ server.tool(
8848
8891
  return cbResult(doc.content);
8849
8892
  }
8850
8893
  const book = await loadTargetCraftbook(t);
8851
- const scripts = t.kind === "task" ? (await api.getTask(t.projectId, t.num)).craftbook.scripts : (await api.getCraftbook(t.id).catch(() => null))?.craftbook.scripts;
8894
+ const template = t.kind === "craftbook" ? (await api.getCraftbook(t.id).catch(() => null))?.craftbook : null;
8895
+ const scripts = t.kind === "task" ? (await api.getTask(t.projectId, t.num)).craftbook.scripts : template?.scripts;
8896
+ const checkup = template && template.id === sessionCraftbookId ? craftbookCheckup(template).map((finding) => finding.message) : null;
8852
8897
  return cbResult(
8853
8898
  JSON.stringify(
8854
8899
  {
8855
8900
  target: describeTarget(t),
8856
8901
  entryStepId: book.entryStepId,
8857
8902
  steps: book.steps,
8858
- ...scripts ? { scripts: Object.keys(scripts) } : {}
8903
+ ...scripts ? { scripts: Object.keys(scripts) } : {},
8904
+ ...checkup ? { checkup } : {}
8859
8905
  },
8860
8906
  null,
8861
8907
  2
@@ -8874,13 +8920,13 @@ server.tool(
8874
8920
  },
8875
8921
  async ({ task, craftbook, create, content, format }) => {
8876
8922
  try {
8877
- if (create) {
8923
+ const t = create ? null : await resolveOptionalCraftbookTarget({ task, craftbook });
8924
+ if (!t) {
8878
8925
  const res2 = await api.createCraftbookDocument({ content, ...format ? { format } : {} });
8879
8926
  return cbResult(
8880
8927
  `Created craftbook "${res2.craftbook.name}" (${res2.craftbook.id}) \u2014 ${res2.gatedSteps} of ${res2.stepCount} steps are gated. Invoke it with invoke_craftbook({ craftbookId: "${res2.craftbook.id}" }).`
8881
8928
  );
8882
8929
  }
8883
- const t = await resolveCraftbookTarget({ task, craftbook });
8884
8930
  if (t.kind === "task") {
8885
8931
  const res2 = await api.putTaskCraftbookDocument(t.projectId, t.num, {
8886
8932
  content,
@@ -10624,7 +10670,7 @@ async function runStartProject(input, tool) {
10624
10670
  if (binaryRequest) {
10625
10671
  return runBinaryDocumentProject({ ...brief, taskTitle, kickoffMessage }, binaryRequest, tool);
10626
10672
  }
10627
- const routed = await routeBriefToProjectType(brief);
10673
+ const routed = await routeBriefToProjectType({ name, about, taskDescription });
10628
10674
  if (routed) {
10629
10675
  const typed = await runTypedKickoff(brief, routed, {
10630
10676
  cacheTool: tool,
@@ -10992,7 +11038,7 @@ async function runFlatProject(input, cacheTool) {
10992
11038
  cacheTool
10993
11039
  );
10994
11040
  }
10995
- const routed = await routeBriefToProjectType(brief);
11041
+ const routed = await routeBriefToProjectType({ name, about, taskDescription });
10996
11042
  if (routed) {
10997
11043
  const typed = await runTypedKickoff(brief, routed, {
10998
11044
  cacheTool,
@@ -12501,9 +12547,10 @@ function inferGeneratedImageSaveAs(prompt) {
12501
12547
  return /\blogo\b/i.test(prompt) ? "assets/logo.png" : void 0;
12502
12548
  }
12503
12549
  var promptGuidesShown = /* @__PURE__ */ new Set();
12550
+ var imageStylesShown = /* @__PURE__ */ new Set();
12504
12551
  server.tool(
12505
12552
  "generate_image",
12506
- "Generate or edit an image from a plain-sentence description; set `aspectRatio` for its shape. When called with just a prompt, produces a fresh image. When `inputImages` is supplied, the prompt acts as an edit/transform on the source(s) \u2014 e.g. 'just like this one but yellow', 'add a hat', 'compose these together'. Routes through whichever image engine the user has selected: the local stable-diffusion.cpp sidecar (default; img2img on a single source), Google Nano Banana 2 (multi-image edits / compositing), or OpenAI GPT Image 2 (edit / compositing). Output PNG is written to the project's `artifacts/generated/` folder and can be read back via `read_artifact`. If the prompt is for a logo and `saveAs` is omitted, the workspace copy defaults to `assets/logo.png` so HTML/CSS can reference a stable path. For shape and size pass `aspectRatio` ('9:16' for a phone wallpaper or story, '16:9' for a banner or slide, '4:5' for a portrait post) and `quality` ('draft' for a quick look, 'high' for a large print); the service fits both to the model. Use width and height only when the user named exact pixels, and omit steps. Write the prompt as sentences describing subject, setting, light and style; put any words the image must show in quotes. **Tip:** to iterate on an image you just generated, pass its `artifactPath` (returned by the previous call) \u2014 far cheaper than re-encoding the bytes. Cloud providers may surface a one-time confirmation card to the user before each call (the user can choose Always allow to silence it). On error the tool returns a message directing the user to the Image generation settings.",
12553
+ "Generate or edit an image from a plain-sentence description; set `aspectRatio` for its shape. When called with just a prompt, produces a fresh image. When `inputImages` is supplied, the prompt acts as an edit/transform on the source(s) \u2014 e.g. 'just like this one but yellow', 'add a hat', 'compose these together'. Routes through whichever image engine the user has selected: the local stable-diffusion.cpp sidecar (default; an editing model such as Qwen Image Edit or FLUX.2 Klein follows the prompt as an instruction on up to three sources), Google Nano Banana 2 (multi-image edits / compositing), or OpenAI GPT Image 2 (edit / compositing). Output PNG is written to the project's `artifacts/generated/` folder and can be read back via `read_artifact`. If the prompt is for a logo and `saveAs` is omitted, the workspace copy defaults to `assets/logo.png` so HTML/CSS can reference a stable path. For shape and size pass `aspectRatio` ('9:16' for a phone wallpaper or story, '16:9' for a banner or slide, '4:5' for a portrait post) and `quality` ('draft' for a quick look, 'high' for a large print); the service fits both to the model. Use width and height only when the user named exact pixels, and omit steps. Write the prompt as sentences describing subject, setting, light and style; put any words the image must show in quotes. **Tip:** to iterate on an image you just generated, pass its `artifactPath` (returned by the previous call) \u2014 far cheaper than re-encoding the bytes. Cloud providers may surface a one-time confirmation card to the user before each call (the user can choose Always allow to silence it). On error the tool returns a message directing the user to the Image generation settings.",
12507
12554
  {
12508
12555
  prompt: z8.string().min(1).describe("What the image should depict, or what edit to apply when `inputImages` is set."),
12509
12556
  negativePrompt: z8.string().optional().describe("Concepts to avoid."),
@@ -12535,10 +12582,16 @@ server.tool(
12535
12582
  })
12536
12583
  ])
12537
12584
  ).optional().describe(
12538
- "Source images for edit / reference-driven generation. Cloud providers accept multiple references for compositing; the local sd-cpp engine uses only the first (img2img). Not every local model supports img2img \u2014 when the resolved model does not, the sources are dropped and the result notes that the image was generated from the prompt alone. Prefer `artifactPath` over base64 when the image lives in the project."
12585
+ "Source images for edit / reference-driven generation. Cloud providers accept multiple references for compositing; the local engine picks an installed editing model, which takes up to three, and older local models use only the first (img2img). When no installed model can edit, the sources are dropped and the result notes that the image was generated from the prompt alone. Prefer `artifactPath` over base64 when the image lives in the project."
12539
12586
  ),
12540
12587
  strength: z8.number().min(0).max(1).optional().describe(
12541
- "Edit strength when `inputImages` is supplied (0 = preserve source, 1 = ignore it). Local sd-cpp only; cloud providers ignore."
12588
+ "Edit strength when `inputImages` is supplied (0 = preserve source, 1 = ignore it). Local img2img models only; editing models and cloud providers ignore it."
12589
+ ),
12590
+ requireEdit: z8.boolean().optional().describe(
12591
+ "Set true when the result must be a change to `inputImages`: fail instead of drawing from the prompt alone when no installed model can edit."
12592
+ ),
12593
+ style: z8.string().optional().describe(
12594
+ 'A look to draw in, by name. Use only when the person asked for one; the result names the styles this model has. With a style, leave medium words such as "photo" out of the prompt: they work against it.'
12542
12595
  ),
12543
12596
  saveAs: z8.string().optional().describe(
12544
12597
  "Workspace-relative path to write the image at (e.g. `logo.png` or `assets/hero.png`). When set, the image lands there instead of the default seed-keyed name \u2014 useful when another gezel will reference the file later (HTML `<img src>`, CSS `url(...)`, etc.) and needs a predictable path. Must be a relative path with no `..` segments and a `.png` / `.jpg` / `.jpeg` / `.webp` extension. Existing files at the same path are overwritten."
@@ -12559,6 +12612,8 @@ server.tool(
12559
12612
  ...args.seed !== void 0 ? { seed: args.seed } : {},
12560
12613
  ...args.inputImages && args.inputImages.length > 0 ? { inputImages: args.inputImages } : {},
12561
12614
  ...args.strength !== void 0 ? { strength: args.strength } : {},
12615
+ ...args.requireEdit ? { requireEdit: true } : {},
12616
+ ...args.style ? { style: args.style } : {},
12562
12617
  ...saveAs ? { saveAs } : {},
12563
12618
  capStepsAtRecommended: true,
12564
12619
  // The daemon holds the size to about a megapixel only when a local
@@ -12578,7 +12633,7 @@ server.tool(
12578
12633
  // Playwright `browser_screenshot` tools use.
12579
12634
  inline: true
12580
12635
  });
12581
- const { meta, artifactPath, workspacePath, b64Png, promptGuide } = res;
12636
+ const { meta, artifactPath, workspacePath, b64Png, promptGuide, styles } = res;
12582
12637
  const workspaceLine = workspacePath ? `
12583
12638
 
12584
12639
  To display this image in HTML, copy this exact tag verbatim \u2014 do not add any prefix, do not change the filename:
@@ -12589,7 +12644,11 @@ If you are working on a website/logo task and an HTML file already exists, your
12589
12644
  const skippedLine = meta.img2imgSkippedReason ? ` NOTE: the source image was not used \u2014 ${meta.img2imgSkippedReason}; the image was generated from the prompt alone.` : "";
12590
12645
  const guideLine = promptGuide && !promptGuidesShown.has(meta.model) ? ` For your next prompt: ${promptGuide}` : "";
12591
12646
  if (promptGuide) promptGuidesShown.add(meta.model);
12592
- const summary = `Generated ${meta.widthPx}\xD7${meta.heightPx} image with ${meta.model} (seed ${meta.seed}, ${meta.steps} steps, ${meta.durationMs}ms).${settingsLine}${skippedLine}${guideLine} The user already sees this image inline below the tool call \u2014 DO NOT embed it again as Markdown (e.g. \`![alt](artifacts/${artifactPath})\`); just refer to it by name in your reply when needed. To iterate on it, pass \`{ inputImages: [{ artifactPath: "${artifactPath}" }] }\` to a follow-up generate_image call. To read its bytes, call \`read_artifact\` with path \`${artifactPath}\`.${workspaceLine}`;
12647
+ const appliedStyle = meta.loras?.find((l) => styles?.some((s) => s.id === l.id));
12648
+ const styleLine = appliedStyle ? ` Style: ${appliedStyle.name}.` : "";
12649
+ const stylesLine = styles?.length && !imageStylesShown.has(meta.model) ? ` Styles this model has: ${styles.map((s) => s.name).join(", ")}.` : "";
12650
+ if (styles?.length) imageStylesShown.add(meta.model);
12651
+ const summary = `Generated ${meta.widthPx}\xD7${meta.heightPx} image with ${meta.model} (seed ${meta.seed}, ${meta.steps} steps, ${meta.durationMs}ms).${styleLine}${settingsLine}${skippedLine}${guideLine}${stylesLine} The user already sees this image inline below the tool call \u2014 DO NOT embed it again as Markdown (e.g. \`![alt](artifacts/${artifactPath})\`); just refer to it by name in your reply when needed. To iterate on it, pass \`{ inputImages: [{ artifactPath: "${artifactPath}" }] }\` to a follow-up generate_image call. To read its bytes, call \`read_artifact\` with path \`${artifactPath}\`.${workspaceLine}`;
12593
12652
  const content = [{ type: "text", text: summary }];
12594
12653
  if (b64Png) {
12595
12654
  content.push({ type: "image", data: b64Png, mimeType: "image/png" });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bendyline/gezel-mcp",
3
- "version": "1.2.11",
3
+ "version": "1.2.12",
4
4
  "description": "Gezel's Model Context Protocol server: gives gezels and other MCP clients access to memory, workspace files, artifacts, tasks, and team tools.",
5
5
  "license": "MIT",
6
6
  "keywords": [
@@ -56,11 +56,11 @@
56
56
  "!dist/**/*.map"
57
57
  ],
58
58
  "dependencies": {
59
- "@bendyline/gezel": "1.2.11",
60
- "@bendyline/gezel-client": "1.2.11",
61
- "@modelcontextprotocol/sdk": "1.31.0",
59
+ "@bendyline/gezel": "1.2.12",
60
+ "@bendyline/gezel-client": "1.2.12",
61
+ "@modelcontextprotocol/sdk": "1.32.2",
62
62
  "typescript": "^6.0.3",
63
- "zod": "^4.4.3"
63
+ "zod": "4.6.7"
64
64
  },
65
65
  "devDependencies": {
66
66
  "@types/node": "^24.13.3",