@mynthio/sdk 0.0.56 → 0.0.57

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/README.md CHANGED
@@ -249,6 +249,16 @@ await mynth.image.generate({
249
249
  });
250
250
  ```
251
251
 
252
+ `magic_prompt` also takes `{ creativity }`, which sets how far the rewrite can go beyond what you wrote. `"none"` refines faithfully without inventing scenes, which is what `true` does. `"balanced"` adds grounded variety, and `"high"` explores wider creative angles. Requests with input images always use `"none"`, and a creative rewrite that fails falls back to the faithful one.
253
+
254
+ ```ts
255
+ await mynth.image.generate({
256
+ model: "black-forest-labs/flux-1-schnell",
257
+ prompt: "A flower",
258
+ magic_prompt: { creativity: "high" },
259
+ });
260
+ ```
261
+
252
262
  ## Size Options
253
263
 
254
264
  `size` supports:
package/dist/index.js CHANGED
@@ -558,7 +558,7 @@ var MynthAPIError = class extends Error {
558
558
  * Sent as `X-Mynth-Client` on creates so Mynth can count SDK traffic. The API
559
559
  * only records it, never checks it. The build inlines the package version.
560
560
  */
561
- const SDK_CLIENT = `sdk/0.0.56`;
561
+ const SDK_CLIENT = `sdk/0.0.57`;
562
562
  /**
563
563
  * Waits before each retry of a create that failed in transit or with a 5xx.
564
564
  * The retry sends the same `Idempotency-Key`, so Mynth returns the task the
@@ -255,10 +255,15 @@ declare namespace MynthSDKTypes {
255
255
  };
256
256
  };
257
257
  type ImageGenerationRequestSize = ImageGenerationRequestSizePreset | ImageGenerationRequestSizeAspectRatio | ImageGenerationRequestSizeAuto | "auto";
258
+ type ImageGenerationRequestMagicPromptCreativity = "none" | "balanced" | "high";
259
+ type ImageGenerationRequestMagicPromptStructured = {
260
+ creativity?: ImageGenerationRequestMagicPromptCreativity;
261
+ };
262
+ type ImageGenerationRequestMagicPrompt = boolean | ImageGenerationRequestMagicPromptStructured;
258
263
  type ImageGenerationRequest = {
259
264
  prompt: ImageGenerationRequestPrompt;
260
265
  negative_prompt?: string;
261
- magic_prompt?: boolean;
266
+ magic_prompt?: ImageGenerationRequestMagicPrompt;
262
267
  model?: ImageGenerationModel;
263
268
  size?: ImageGenerationRequestSize;
264
269
  count?: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mynthio/sdk",
3
- "version": "0.0.56",
3
+ "version": "0.0.57",
4
4
  "description": "Official Mynth SDK for image generation and analysis",
5
5
  "keywords": [
6
6
  "ai",