image-router-mcp 0.1.2 → 0.1.3
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.
- package/README.md +8 -8
- package/dist/schemas.d.ts +2 -2
- package/dist/schemas.js +2 -2
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -22,7 +22,7 @@ It keeps model IDs flexible instead of locking tools to a small allowlist, so ne
|
|
|
22
22
|
| Tool | Provider | Supports |
|
|
23
23
|
| --- | --- | --- |
|
|
24
24
|
| `xai_generate_image` | xAI/Grok | Text-to-image and JSON image edits with up to 3 local `input_images` |
|
|
25
|
-
| `google_generate_image` | Google Gemini/Nano Banana | Text-to-image and local reference/edit images, including `
|
|
25
|
+
| `google_generate_image` | Google Gemini/Nano Banana | Text-to-image and local reference/edit images, including `0.5K`, `1K`, `2K`, and `4K` image sizes where supported |
|
|
26
26
|
| `openai_generate_image` | OpenAI | Text-to-image and local reference/edit images |
|
|
27
27
|
|
|
28
28
|
## Model examples
|
|
@@ -32,7 +32,7 @@ These are examples, not allowlists.
|
|
|
32
32
|
| Provider | Example models |
|
|
33
33
|
| --- | --- |
|
|
34
34
|
| xAI | `grok-imagine-image-quality`, `grok-imagine-image` |
|
|
35
|
-
| Google | `gemini-3.1-flash-image
|
|
35
|
+
| Google | `gemini-3.1-flash-image`, `gemini-3-pro-image`, `gemini-2.5-flash-image` |
|
|
36
36
|
| OpenAI | `gpt-image-2`, `gpt-image-1.5`, `gpt-image-1`, `chatgpt-image-latest`, `dall-e-3` |
|
|
37
37
|
|
|
38
38
|
## Quick start
|
|
@@ -99,10 +99,10 @@ To edit or reference existing local images, pass file paths with `input_images`:
|
|
|
99
99
|
"tool": "google_generate_image",
|
|
100
100
|
"arguments": {
|
|
101
101
|
"prompt": "Turn this sketch into a polished mobile app hero illustration",
|
|
102
|
-
"model": "gemini-3.1-flash-image
|
|
102
|
+
"model": "gemini-3.1-flash-image",
|
|
103
103
|
"input_images": ["./assets/sketch.png"],
|
|
104
104
|
"aspect_ratio": "16:9",
|
|
105
|
-
"image_size": "
|
|
105
|
+
"image_size": "0.5K",
|
|
106
106
|
"return_mode": "both"
|
|
107
107
|
}
|
|
108
108
|
}
|
|
@@ -147,7 +147,7 @@ npm run ci
|
|
|
147
147
|
| 工具 | 供應商 | 支援內容 |
|
|
148
148
|
| --- | --- | --- |
|
|
149
149
|
| `xai_generate_image` | xAI/Grok | 文字生成圖片,以及最多 3 張本機 `input_images` 的 JSON 圖片編輯 |
|
|
150
|
-
| `google_generate_image` | Google Gemini/Nano Banana | 文字生成圖片,以及本機參考圖/編輯圖;支援供應商允許的 `
|
|
150
|
+
| `google_generate_image` | Google Gemini/Nano Banana | 文字生成圖片,以及本機參考圖/編輯圖;支援供應商允許的 `0.5K`、`1K`、`2K`、`4K` 圖片尺寸 |
|
|
151
151
|
| `openai_generate_image` | OpenAI | 文字生成圖片,以及本機參考圖/編輯圖 |
|
|
152
152
|
|
|
153
153
|
## 模型範例
|
|
@@ -157,7 +157,7 @@ npm run ci
|
|
|
157
157
|
| 供應商 | 模型範例 |
|
|
158
158
|
| --- | --- |
|
|
159
159
|
| xAI | `grok-imagine-image-quality`, `grok-imagine-image` |
|
|
160
|
-
| Google | `gemini-3.1-flash-image
|
|
160
|
+
| Google | `gemini-3.1-flash-image`, `gemini-3-pro-image`, `gemini-2.5-flash-image` |
|
|
161
161
|
| OpenAI | `gpt-image-2`, `gpt-image-1.5`, `gpt-image-1`, `chatgpt-image-latest`, `dall-e-3` |
|
|
162
162
|
|
|
163
163
|
## 快速開始
|
|
@@ -224,10 +224,10 @@ npm run build
|
|
|
224
224
|
"tool": "google_generate_image",
|
|
225
225
|
"arguments": {
|
|
226
226
|
"prompt": "Turn this sketch into a polished mobile app hero illustration",
|
|
227
|
-
"model": "gemini-3.1-flash-image
|
|
227
|
+
"model": "gemini-3.1-flash-image",
|
|
228
228
|
"input_images": ["./assets/sketch.png"],
|
|
229
229
|
"aspect_ratio": "16:9",
|
|
230
|
-
"image_size": "
|
|
230
|
+
"image_size": "0.5K",
|
|
231
231
|
"return_mode": "both"
|
|
232
232
|
}
|
|
233
233
|
}
|
package/dist/schemas.d.ts
CHANGED
|
@@ -50,7 +50,7 @@ export declare const googleInputShape: {
|
|
|
50
50
|
readonly model: z.ZodDefault<z.ZodString>;
|
|
51
51
|
readonly aspect_ratio: z.ZodOptional<z.ZodString>;
|
|
52
52
|
readonly image_size: z.ZodOptional<z.ZodEnum<{
|
|
53
|
-
|
|
53
|
+
"0.5K": "0.5K";
|
|
54
54
|
"1K": "1K";
|
|
55
55
|
"2K": "2K";
|
|
56
56
|
"4K": "4K";
|
|
@@ -131,7 +131,7 @@ export declare const googleParamsSchema: z.ZodObject<{
|
|
|
131
131
|
model: z.ZodDefault<z.ZodString>;
|
|
132
132
|
aspect_ratio: z.ZodOptional<z.ZodString>;
|
|
133
133
|
image_size: z.ZodOptional<z.ZodEnum<{
|
|
134
|
-
|
|
134
|
+
"0.5K": "0.5K";
|
|
135
135
|
"1K": "1K";
|
|
136
136
|
"2K": "2K";
|
|
137
137
|
"4K": "4K";
|
package/dist/schemas.js
CHANGED
|
@@ -33,9 +33,9 @@ export const openAIInputShape = {
|
|
|
33
33
|
};
|
|
34
34
|
export const googleInputShape = {
|
|
35
35
|
...commonImageShape,
|
|
36
|
-
model: nonEmptyString.default("gemini-3.1-flash-image
|
|
36
|
+
model: nonEmptyString.default("gemini-3.1-flash-image").describe("Google image model ID. Defaults to Nano Banana 2."),
|
|
37
37
|
aspect_ratio: nonEmptyString.optional().describe("Aspect ratio, for example 1:1, 16:9, 9:16, 4:3, or 3:2."),
|
|
38
|
-
image_size: z.enum(["
|
|
38
|
+
image_size: z.enum(["0.5K", "1K", "2K", "4K"]).optional().describe("Google image size where supported."),
|
|
39
39
|
};
|
|
40
40
|
export const xaiInputShape = {
|
|
41
41
|
...commonImageShape,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "image-router-mcp",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"description": "MCP server for routing image generation and editing across xAI, Google Gemini/Nano Banana, and OpenAI.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -33,9 +33,9 @@
|
|
|
33
33
|
"author": "",
|
|
34
34
|
"license": "MIT",
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@google/genai": "2.
|
|
36
|
+
"@google/genai": "2.9.0",
|
|
37
37
|
"@modelcontextprotocol/sdk": "1.29.0",
|
|
38
|
-
"openai": "6.
|
|
38
|
+
"openai": "6.44.0",
|
|
39
39
|
"zod": "4.4.3"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|