fix(baoyu-image-gen): require OpenRouter image parameters
This commit is contained in:
parent
1af984a64f
commit
efb7a1917a
|
|
@ -39,6 +39,9 @@ test("OpenRouter request body uses image_config and string content for text-only
|
||||||
image_size: "2K",
|
image_size: "2K",
|
||||||
aspect_ratio: "16:9",
|
aspect_ratio: "16:9",
|
||||||
});
|
});
|
||||||
|
assert.deepEqual(body.provider, {
|
||||||
|
require_parameters: true,
|
||||||
|
});
|
||||||
assert.equal(body.stream, false);
|
assert.equal(body.stream, false);
|
||||||
assert.equal(body.messages[0].content, "hello");
|
assert.equal(body.messages[0].content, "hello");
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -234,6 +234,9 @@ export function buildRequestBody(
|
||||||
],
|
],
|
||||||
modalities: ["image", "text"],
|
modalities: ["image", "text"],
|
||||||
image_config: imageConfig,
|
image_config: imageConfig,
|
||||||
|
provider: {
|
||||||
|
require_parameters: true,
|
||||||
|
},
|
||||||
stream: false,
|
stream: false,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue