{"version":3,"file":"OpenAIImageGenerator.test.mjs","names":["OpenAIImageGenerator.sizeOf","OpenAIImageGenerator.editForm","OpenAIImageGenerator.decodeImagesResponse","OpenAIImageGenerator.toResponse","OpenAIImageGenerator.imageHttpError","OpenAIImageGenerator.imageStreamError","OpenAIImageGenerator.streamEventOf"],"sources":["../src/OpenAIImageGenerator.test.ts"],"sourcesContent":["import { describe, it } from \"@effect/vitest\"\nimport { Cause, Effect, Exit, Option } from \"effect\"\nimport { expect } from \"vitest\"\nimport type * as AiError from \"@effect-uai/core/AiError\"\nimport { imageBase64, imageBytes, imageUrl } from \"@effect-uai/core/Image\"\nimport { ImageStreamEvent } from \"@effect-uai/core/ImageGenerator\"\nimport * as OpenAIImageGenerator from \"./OpenAIImageGenerator.js\"\n\nconst errorOf = <A, E>(exit: Exit.Exit<A, E>): E | undefined =>\n  Exit.isFailure(exit) ? Option.getOrUndefined(Cause.findErrorOption(exit.cause)) : undefined\n\nconst frame = (data: unknown) => ({ data: JSON.stringify(data) })\n\ndescribe(\"sizeOf\", () => {\n  it.effect(\"puts the tier on the short edge and scales the long one to the ratio\", () =>\n    Effect.gen(function* () {\n      // Landscape scales the width, portrait the height, both rounded to the\n      // multiple of 16 the endpoint requires (16:9 of 2048 is 3640.9).\n      expect(yield* OpenAIImageGenerator.sizeOf({ aspectRatio: \"16:9\", resolution: \"2K\" })).toBe(\n        \"3648x2048\",\n      )\n      expect(yield* OpenAIImageGenerator.sizeOf({ aspectRatio: \"9:16\", resolution: \"1K\" })).toBe(\n        \"1024x1824\",\n      )\n      // Half a request still derives: square without a ratio, 1K without a tier.\n      expect(yield* OpenAIImageGenerator.sizeOf({ resolution: \"4K\" })).toBe(\"4096x4096\")\n      expect(yield* OpenAIImageGenerator.sizeOf({ aspectRatio: \"3:2\" })).toBe(\"1536x1024\")\n    }),\n  )\n\n  it.effect(\"lets an explicit `size` win over the ratio and tier\", () =>\n    Effect.gen(function* () {\n      const size = yield* OpenAIImageGenerator.sizeOf({\n        size: \"1536x1024\",\n        aspectRatio: \"1:1\",\n        resolution: \"4K\",\n      })\n      expect(size).toBe(\"1536x1024\")\n    }),\n  )\n\n  it.effect(\"fails InvalidRequest on a ratio it cannot turn into pixels\", () =>\n    Effect.gen(function* () {\n      for (const aspectRatio of [\"wide\", \"-16:9\", \"0:1\", \"16:9:4\", \"16\"]) {\n        const exit = yield* Effect.exit(OpenAIImageGenerator.sizeOf({ aspectRatio }))\n        const error = errorOf(exit)\n        expect(error?._tag, aspectRatio).toBe(\"InvalidRequest\")\n        expect((error as AiError.InvalidRequest).param).toBe(\"aspectRatio\")\n      }\n    }),\n  )\n})\n\ndescribe(\"editForm\", () => {\n  const editRequest = {\n    prompt: \"make it dawn\",\n    model: \"gpt-image-2\",\n    images: [imageBase64(\"aW1n\", \"image/png\"), imageBytes(new Uint8Array([1, 2, 3]), \"image/webp\")],\n    mask: imageBase64(\"bWFzaw==\", \"image/png\"),\n    quality: \"high\",\n  } as const\n\n  it.effect(\"uploads several references as repeated `image[]` parts, named by format\", () =>\n    Effect.gen(function* () {\n      const form = yield* OpenAIImageGenerator.editForm(editRequest)\n      const images = form.getAll(\"image[]\") as ReadonlyArray<File>\n      expect(images.map((f) => f.name)).toEqual([\"image-0.png\", \"image-1.webp\"])\n      expect(images.map((f) => f.type)).toEqual([\"image/png\", \"image/webp\"])\n      expect((form.get(\"mask\") as File).name).toBe(\"image-0.png\")\n      // Knobs ride along as strings, as multipart requires.\n      expect(form.get(\"quality\")).toBe(\"high\")\n      expect(form.get(\"model\")).toBe(\"gpt-image-2\")\n    }),\n  )\n\n  it.effect(\"sends a lone reference as `image`, the endpoint's required field\", () =>\n    Effect.gen(function* () {\n      // `image[]` is the multi-file spelling only. A server implementing just\n      // the single-file schema rejects it with \"Missing required parameter\".\n      const form = yield* OpenAIImageGenerator.editForm({\n        ...editRequest,\n        images: [imageBase64(\"aW1n\", \"image/png\")],\n      })\n      expect((form.get(\"image\") as File).name).toBe(\"image-0.png\")\n      expect(form.getAll(\"image[]\")).toEqual([])\n    }),\n  )\n\n  it(\"rejects a URL reference at compile time: multipart uploads bytes\", () => {\n    const url = imageUrl(\"https://example.com/a.png\", \"image/png\")\n    // @ts-expect-error: `images` is narrowed to the inline variants.\n    const request: OpenAIImageGenerator.OpenAIImageEditRequest = { ...editRequest, images: [url] }\n    expect(request).toBeDefined()\n  })\n\n  it.effect(\"still fails InvalidRequest when a URL arrives through the generic tag\", () =>\n    Effect.gen(function* () {\n      // The generic `edit` takes the full `ImageSource` union and the Layer\n      // casts, so the runtime rejection stays as the backstop.\n      const exit = yield* Effect.exit(\n        OpenAIImageGenerator.editForm({\n          ...editRequest,\n          images: [imageUrl(\"https://example.com/a.png\", \"image/png\") as never],\n        }),\n      )\n      const error = errorOf(exit)\n      expect(error?._tag).toBe(\"InvalidRequest\")\n      expect((error as AiError.InvalidRequest).param).toBe(\"images\")\n    }),\n  )\n})\n\ndescribe(\"response decoding\", () => {\n  const decode = (json: unknown, requested?: \"png\" | \"jpeg\" | \"webp\") =>\n    Effect.flatMap(OpenAIImageGenerator.decodeImagesResponse(json), (wire) =>\n      OpenAIImageGenerator.toResponse(wire, requested),\n    )\n\n  it.effect(\"resolves the MIME from the echoed format, then the requested one, then png\", () =>\n    Effect.gen(function* () {\n      const echoed = yield* decode({ data: [{ b64_json: \"aW1n\" }], output_format: \"webp\" }, \"jpeg\")\n      expect(echoed.images[0]!.image).toEqual(imageBase64(\"aW1n\", \"image/webp\"))\n      const requested = yield* decode({ data: [{ b64_json: \"aW1n\" }] }, \"jpeg\")\n      expect(requested.images[0]!.image).toEqual(imageBase64(\"aW1n\", \"image/jpeg\"))\n      const fallback = yield* decode({ data: [{ b64_json: \"aW1n\" }] })\n      expect(fallback.images[0]!.image).toEqual(imageBase64(\"aW1n\", \"image/png\"))\n    }),\n  )\n\n  it.effect(\"maps usage and accepts the narrower payload a gateway returns\", () =>\n    Effect.gen(function* () {\n      const full = yield* decode({\n        created: 1,\n        data: [{ b64_json: \"aW1n\" }],\n        usage: { input_tokens: 12, output_tokens: 1120, total_tokens: 1132 },\n      })\n      expect(full.usage).toEqual({ inputTokens: 12, outputTokens: 1120, totalTokens: 1132 })\n      // No `created`, no `usage`, and a URL where GPT image models send base64.\n      const subset = yield* decode({ data: [{ url: \"https://cdn.example.com/a.png\" }] })\n      expect(subset.images).toEqual([\n        { image: imageUrl(\"https://cdn.example.com/a.png\", \"image/png\") },\n      ])\n      expect(subset.usage).toEqual({})\n    }),\n  )\n\n  it.effect(\"fails GenerationFailed when no entry carries an image\", () =>\n    Effect.gen(function* () {\n      const exit = yield* Effect.exit(decode({ created: 1, data: [{ revised_prompt: \"...\" }] }))\n      expect(errorOf(exit)?._tag).toBe(\"GenerationFailed\")\n    }),\n  )\n})\n\ndescribe(\"error classification\", () => {\n  it.effect(\"maps a moderation block to ContentFiltered, carrying the message\", () =>\n    Effect.gen(function* () {\n      const body = JSON.stringify({\n        error: {\n          type: \"image_generation_user_error\",\n          code: \"moderation_blocked\",\n          message: \"Your request was rejected.\",\n        },\n      })\n      const error = yield* OpenAIImageGenerator.imageHttpError(400, body)\n      expect(error._tag).toBe(\"ContentFiltered\")\n      expect((error as AiError.ContentFiltered).reason).toBe(\"Your request was rejected.\")\n    }),\n  )\n\n  it.effect(\"leaves every other error to the shared status mapping\", () =>\n    Effect.gen(function* () {\n      const other = JSON.stringify({ error: { code: \"invalid_value\", message: \"bad size\" } })\n      expect((yield* OpenAIImageGenerator.imageHttpError(400, other))._tag).toBe(\"InvalidRequest\")\n      expect((yield* OpenAIImageGenerator.imageHttpError(429, other))._tag).toBe(\"RateLimited\")\n      // A body that is not JSON at all still classifies by status.\n      expect((yield* OpenAIImageGenerator.imageHttpError(503, \"<html>\"))._tag).toBe(\"Unavailable\")\n    }),\n  )\n\n  it.effect(\"treats a non-moderation failure mid-stream as GenerationFailed\", () =>\n    Effect.gen(function* () {\n      // The HTTP status was 200, so the status mapping has nothing to say.\n      const error = yield* OpenAIImageGenerator.imageStreamError(\n        JSON.stringify({ error: { code: \"server_error\" } }),\n      )\n      expect(error._tag).toBe(\"GenerationFailed\")\n    }),\n  )\n})\n\ndescribe(\"stream frames\", () => {\n  it.effect(\"discriminates partials from the completed frame\", () =>\n    Effect.gen(function* () {\n      const partial = yield* OpenAIImageGenerator.streamEventOf(\n        frame({\n          type: \"image_generation.partial_image\",\n          b64_json: \"cDE=\",\n          partial_image_index: 1,\n          output_format: \"webp\",\n        }),\n        undefined,\n      )\n      expect(partial).toEqual(\n        ImageStreamEvent.PartialImage({ image: imageBase64(\"cDE=\", \"image/webp\"), index: 1 }),\n      )\n\n      const completed = yield* OpenAIImageGenerator.streamEventOf(\n        frame({\n          type: \"image_generation.completed\",\n          b64_json: \"ZG9uZQ==\",\n          usage: { total_tokens: 1132 },\n        }),\n        undefined,\n      )\n      expect(completed).toEqual(\n        ImageStreamEvent.Complete({\n          images: [{ image: imageBase64(\"ZG9uZQ==\", \"image/png\") }],\n          usage: { totalTokens: 1132 },\n        }),\n      )\n    }),\n  )\n\n  it.effect(\"drops frames it has no representation for instead of failing the stream\", () =>\n    Effect.gen(function* () {\n      const unknown = yield* OpenAIImageGenerator.streamEventOf(\n        frame({ type: \"image_generation.queued\" }),\n        undefined,\n      )\n      expect(unknown).toBeUndefined()\n      const garbage = yield* OpenAIImageGenerator.streamEventOf({ data: \"not json\" }, undefined)\n      expect(garbage).toBeUndefined()\n    }),\n  )\n\n  it.effect(\"fails the stream on an error frame, moderation included\", () =>\n    Effect.gen(function* () {\n      const blocked = yield* Effect.exit(\n        OpenAIImageGenerator.streamEventOf(\n          { event: \"error\", data: JSON.stringify({ error: { code: \"moderation_blocked\" } }) },\n          undefined,\n        ),\n      )\n      expect(errorOf(blocked)?._tag).toBe(\"ContentFiltered\")\n\n      const broke = yield* Effect.exit(\n        OpenAIImageGenerator.streamEventOf({ event: \"error\", data: \"boom\" }, undefined),\n      )\n      expect(errorOf(broke)?._tag).toBe(\"GenerationFailed\")\n    }),\n  )\n})\n"],"mappings":";;;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