Skip to content

armgit / hypit

Public Imported from GitHub
0

Clone any viral video with AI agents. Not just a script, the whole workflow: swap the face, the words, the B-roll, ship 100 variants in one command, and get your 100M views.

feat(gpt-image): accept 21:9 requests

kashorinaf1c195afc2c
diff --git a/packages/gpt-image/src/index.ts b/packages/gpt-image/src/index.ts
index 0400c69c..69b4048f 100644
--- a/packages/gpt-image/src/index.ts
+++ b/packages/gpt-image/src/index.ts
@@ -21,10 +21,7 @@ export const gptImage2Ports: GenerationPortTable = sealGenerationPortTable({
name: "aspectRatio",
value: {
kind: "enum",
- // What the model produces. The wider shapes an image API will name in general — 2:1, 3:1,
- // 21:9 and their inverses — this one refuses, and the refusal arrives from the Provider
- // after the request was made rather than from validation before it.
- values: ["auto", "1:1", "3:2", "2:3", "4:3", "3:4", "5:4", "4:5", "16:9", "9:16"],
+ values: ["auto", "1:1", "3:2", "2:3", "4:3", "3:4", "5:4", "4:5", "16:9", "9:16", "21:9"],
},
minItems: 1,
maxItems: 1,
@@ -79,7 +76,7 @@ const gptImageAttributes: readonly SurfaceAttributeVocabulary[] = [
kind: "literal",
required: true,
summary: "The shape of the generated picture.",
- values: ["auto", "1:1", "3:2", "2:3", "4:3", "3:4", "5:4", "4:5", "16:9", "9:16"],
+ values: ["auto", "1:1", "3:2", "2:3", "4:3", "3:4", "5:4", "4:5", "16:9", "9:16", "21:9"],
},
{
name: "resolution",
diff --git a/packages/gpt-image/test/surface.test.ts b/packages/gpt-image/test/surface.test.ts
index 9ce5cea1..c45254bd 100644
--- a/packages/gpt-image/test/surface.test.ts
+++ b/packages/gpt-image/test/surface.test.ts
@@ -36,7 +36,7 @@ async function decode(source: string, handler: StructuredSurfaceHandler) {
});
}
-const authored = `<gpt:Image id="holding" prompt={prompt} aspect-ratio="9:16" resolution="2K">
+const authored = `<gpt:Image id="holding" prompt={prompt} aspect-ratio="21:9" resolution="2K">
<gpt:Reference image={person.image}/>
<gpt:Reference image={product.image}/>
</gpt:Image>`;