@doufunao123/asset-gateway 0.8.1 → 0.9.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.
Files changed (2) hide show
  1. package/dist/index.js +4 -1
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -527,7 +527,7 @@ async function saveOutput(result, assetType, outputDir) {
527
527
  function createGenerateCommand() {
528
528
  const command = new Command3("generate").description("Generate assets via the gateway");
529
529
  command.addCommand(
530
- new Command3("image").description("Generate an image from a text prompt").requiredOption("--prompt <text>", "Image description prompt").option("--provider <id>", "Provider to use").option("--transparent", "Request transparent background").option("--model <model>", "Model to use").option("--size <size>", "Image size (e.g. 1024x1024)").option("--input <url>", "Input image URL for editing (Gemini/Grok)").option("--output-dir <dir>", "Directory to save output", ".").action(async function(options) {
530
+ new Command3("image").description("Generate an image from a text prompt").requiredOption("--prompt <text>", "Image description prompt").option("--provider <id>", "Provider to use").option("--transparent", "Request transparent background").option("--model <model>", "Model to use").option("--size <size>", "Image size (e.g. 1024x1024)").option("--input <url>", "Input image URL for editing (Gemini/Grok)").option("--ref <urls...>", "Reference image URLs for multi-image editing (repeatable)").option("--edit-mode <mode>", "Edit mode: edit, inpaint, restyle, expand").option("--session <id>", "Session ID for multi-turn editing").option("--output-dir <dir>", "Directory to save output", ".").action(async function(options) {
531
531
  try {
532
532
  const ctx = createContext(this);
533
533
  const body = {
@@ -539,6 +539,9 @@ function createGenerateCommand() {
539
539
  if (options.model) body.model = options.model;
540
540
  if (options.size) body.size = options.size;
541
541
  if (options.input) body.input_file = options.input;
542
+ if (options.ref && options.ref.length > 0) body.reference_images = options.ref;
543
+ if (options.editMode) body.edit_mode = options.editMode;
544
+ if (options.session) body.session_id = options.session;
542
545
  const data = await ctx.client.post("/api/generate", body);
543
546
  const localPath = await saveOutput(data, "image", options.outputDir);
544
547
  if (localPath) data.local_path = localPath;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@doufunao123/asset-gateway",
3
- "version": "0.8.1",
3
+ "version": "0.9.0",
4
4
  "description": "Universal asset generation gateway CLI",
5
5
  "type": "module",
6
6
  "bin": {