@chrischall/gemini-mcp 1.6.2 → 1.7.0
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/.claude-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +1 -1
- package/dist/bundle.js +336 -21
- package/dist/client.js +25 -0
- package/dist/job-store.js +138 -0
- package/dist/jobs.js +257 -12
- package/dist/session.js +5 -4
- package/dist/storage/media.js +70 -0
- package/dist/tools/files.js +49 -0
- package/dist/tools/jobs.js +5 -1
- package/dist/tools/shared.js +13 -3
- package/dist/version.js +1 -1
- package/package.json +1 -1
- package/server.json +2 -2
package/dist/tools/jobs.js
CHANGED
|
@@ -11,7 +11,11 @@ import { z } from 'zod';
|
|
|
11
11
|
// other session's result by job id — see src/session.ts.
|
|
12
12
|
export function registerJobTools(server, client) {
|
|
13
13
|
server.registerTool('gemini_get_result', {
|
|
14
|
-
description: 'Retrieve
|
|
14
|
+
description: 'Retrieve a generation started with `async: true` or handed off by `max_wait_ms`. Pass the returned `job_id`: ' +
|
|
15
|
+
'while running it reports status "running"; on completion it returns the normal result (image URLs/paths + meta); ' +
|
|
16
|
+
'on failure it raises the recorded error, including the case where the generation was killed before it finished. ' +
|
|
17
|
+
'On the hosted connector job records are stored durably and survive a restart; on a local stdio server they live ' +
|
|
18
|
+
'with the process and expire ~10 min after completion, where the output dir / <image>.json sidecar is the fallback.',
|
|
15
19
|
annotations: { readOnlyHint: true, openWorldHint: false },
|
|
16
20
|
inputSchema: {
|
|
17
21
|
job_id: z.string().min(1).describe('The job_id returned by a generation tool called with async: true'),
|
package/dist/tools/shared.js
CHANGED
|
@@ -55,7 +55,10 @@ export const idempotencyKeySchema = z
|
|
|
55
55
|
export const asyncSchema = z
|
|
56
56
|
.boolean()
|
|
57
57
|
.optional()
|
|
58
|
-
.describe('Run in the background and return a job_id immediately instead of the image, so a long (Pro/4K) generation cannot hit
|
|
58
|
+
.describe('Run in the background and return a job_id immediately instead of the image, so a long (Pro/4K) generation cannot hit ' +
|
|
59
|
+
'the host tools/call timeout (-32001). Poll gemini_get_result with the job_id to fetch the result. ' +
|
|
60
|
+
'PREFER `max_wait_ms` on the hosted connector: it runs where the executor is only guaranteed to stay alive while the ' +
|
|
61
|
+
'request is open, so this option is served there as a bounded wait rather than an immediate hand-off.');
|
|
59
62
|
/**
|
|
60
63
|
* Wait-then-hand-off budget shared by every generation tool: wait up to the
|
|
61
64
|
* budget for the in-band result, and past it return a `{ job_id }` handle
|
|
@@ -361,10 +364,17 @@ export function timeoutRiskHint(opts) {
|
|
|
361
364
|
.join(' + ');
|
|
362
365
|
const lead = `Slow config (${why}) can exceed a host's tools/call timeout (e.g. Claude Desktop ~30s, error -32001). `;
|
|
363
366
|
if (opts.persistsFiles === false) {
|
|
367
|
+
// Deliberately NOT `async: true`. This connector runs on a machine that is
|
|
368
|
+
// stopped whenever no request is in flight, so an immediate hand-off is
|
|
369
|
+
// what gets a generation killed mid-flight; holding the request open is
|
|
370
|
+
// what keeps it alive. Recommending async here was recommending the
|
|
371
|
+
// failure mode (see src/job-store.ts).
|
|
364
372
|
return (lead +
|
|
365
373
|
`This connector has no filesystem, so a lost response cannot be recovered from disk — there is no output dir and no ` +
|
|
366
|
-
`<image>.json sidecar.
|
|
367
|
-
`
|
|
374
|
+
`<image>.json sidecar. Set \`max_wait_ms\` (e.g. 240000): keeping the request open is also what keeps the generation ` +
|
|
375
|
+
`running here, and a batch that outlives the budget hands back a job_id to poll with gemini_get_result. ` +
|
|
376
|
+
`For a faster in-band result use a Flash model or drop image_size to 1K/2K. If a result is ever lost, ` +
|
|
377
|
+
`list what was already generated with gemini_list_recent_media before paying for it again.`);
|
|
368
378
|
}
|
|
369
379
|
return (lead +
|
|
370
380
|
`If the host gives up mid-generation the image is still written to disk (and gemini_interact leaves an ` +
|
package/dist/version.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/** Single source of the server version. release-please bumps the literal below. */
|
|
2
|
-
export const VERSION = '1.
|
|
2
|
+
export const VERSION = '1.7.0'; // x-release-please-version
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@chrischall/gemini-mcp",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0",
|
|
4
4
|
"mcpName": "io.github.chrischall/gemini-mcp",
|
|
5
5
|
"description": "Gemini image-generation MCP server for Claude — developed and maintained by AI (Claude Code)",
|
|
6
6
|
"author": "Claude Code (AI) <https://www.anthropic.com/claude>",
|
package/server.json
CHANGED
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
"url": "https://github.com/chrischall/gemini-mcp",
|
|
7
7
|
"source": "github"
|
|
8
8
|
},
|
|
9
|
-
"version": "1.
|
|
9
|
+
"version": "1.7.0",
|
|
10
10
|
"packages": [
|
|
11
11
|
{
|
|
12
12
|
"registryType": "npm",
|
|
13
13
|
"identifier": "@chrischall/gemini-mcp",
|
|
14
|
-
"version": "1.
|
|
14
|
+
"version": "1.7.0",
|
|
15
15
|
"transport": {
|
|
16
16
|
"type": "stdio"
|
|
17
17
|
},
|