opencode-gpt-imagegen
Advanced tools
+1
-1
@@ -42,3 +42,3 @@ // src/index.ts | ||
| const json = JSON.parse(event.data); | ||
| if (json.type === "response.output_item.done" && json.item?.type === "image_generation_call" && typeof json.item.result === "string") { | ||
| if (json.type === "response.output_item.done" && json.item?.type === "image_generation_call" && typeof json.item.result === "string" && json.item.result.length > 0) { | ||
| return json.item.result; | ||
@@ -45,0 +45,0 @@ } |
+4
-4
| { | ||
| "name": "opencode-gpt-imagegen", | ||
| "version": "0.1.8", | ||
| "version": "0.1.9", | ||
| "description": "OpenCode plugin for GPT Image 2 generation through your ChatGPT subscription, with reference images and safe PNG output.", | ||
@@ -22,4 +22,4 @@ "type": "module", | ||
| "build": "bun build ./src/index.ts --outdir ./dist --target node --format esm --packages external", | ||
| "test": "bun test", | ||
| "test:e2e": "OPENCODE_MODEL=openai/gpt-5.5 RUN_E2E=1 bun test", | ||
| "test": "bun test tests/unit", | ||
| "test:e2e_subscription": "OPENCODE_MODEL=openai/gpt-5.5 bun test tests/e2e/subscription.test.ts", | ||
| "prepublishOnly": "bun run build", | ||
@@ -60,3 +60,3 @@ "release:patch": "bash scripts/prepare-release.sh patch && git push --follow-tags", | ||
| "devDependencies": { | ||
| "@biomejs/biome": "2.4.16", | ||
| "@biomejs/biome": "2.5.2", | ||
| "@opencode-ai/plugin": "^1.14.41", | ||
@@ -63,0 +63,0 @@ "@tsconfig/node22": "^22.0.2", |
+1
-1
@@ -39,3 +39,3 @@ # opencode-gpt-imagegen | ||
| The three examples below are the **actual outputs of this repo's e2e test suite** — see [`tests/e2e.test.ts`](./tests/e2e.test.ts) for the exact prompts and assertions. | ||
| The three examples below are the **actual outputs of this repo's e2e test suite** — see [`tests/e2e/subscription.test.ts`](./tests/e2e/subscription.test.ts) for the exact prompts and assertions. | ||
@@ -42,0 +42,0 @@ ### Example A — generate |
AI-detected potential code anomaly
Supply chain riskAI has identified unusual behaviors that may pose a security risk.
16024
0.63%7
16.67%