@lifesi/genesis-mcp 0.1.3 → 0.1.5
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/dist/hives-node-transport.js +1 -1
- package/dist/server.js +1 -1
- package/dist/tools.js +3 -3
- package/package.json +2 -2
|
@@ -13,7 +13,7 @@ export async function closeHivesNodeTransport() {
|
|
|
13
13
|
export function hivesOperationBudget(id) {
|
|
14
14
|
if (['hives_list_buckets', 'hives_create_bucket', 'hives_get_bucket', 'hives_delete_bucket', 'hives_list_objects', 'hives_upload_object', 'hives_upload_object_by_key', 'hives_delete_object', 'hives_delete_object_by_key', 'hives_download_object_by_key', 'hives_get_cors_config', 'hives_set_cors_config', 'hives_generate_presigned_url', 'hives_reconcile'].includes(id))
|
|
15
15
|
return 100_000;
|
|
16
|
-
if (id === 'hives_cancel_deployment' || id === 'hives_delete_deployment')
|
|
16
|
+
if (id === 'hives_cancel_deployment' || id === 'hives_delete_deployment' || id === 'hives_stop_deployment')
|
|
17
17
|
return 330_000;
|
|
18
18
|
if (['hives_create_deployment', 'hives_upload_deployment', 'hives_invoke_deployment', 'hives_invoke_function', 'hives_invoke_function_async'].includes(id))
|
|
19
19
|
return 40_000;
|
package/dist/server.js
CHANGED
|
@@ -5,7 +5,7 @@ import { CallToolRequestSchema, ListToolsRequestSchema } from '@modelcontextprot
|
|
|
5
5
|
import http from 'node:http';
|
|
6
6
|
import { callTool, tools } from './tools.js';
|
|
7
7
|
export function createServer(opts = {}) {
|
|
8
|
-
const server = new Server({ name: 'genesis', version: '0.1.
|
|
8
|
+
const server = new Server({ name: 'genesis', version: '0.1.5' }, {
|
|
9
9
|
capabilities: { tools: {} },
|
|
10
10
|
instructions: 'Genesis: one API for Foundry (inference), Hives (compute), Relays (DNS) and LifeID keys. Use the named tools for common tasks; use genesis_search_tools + genesis_call for anything else.',
|
|
11
11
|
});
|
package/dist/tools.js
CHANGED
|
@@ -18,7 +18,7 @@ function describe(id, op) {
|
|
|
18
18
|
return `${op.summary} (${op.method} ${op.path})${status}`;
|
|
19
19
|
}
|
|
20
20
|
const annotate = (op, id) => ({
|
|
21
|
-
readOnlyHint: op.method === 'GET', destructiveHint: op.method === 'DELETE' || isHivesResourceTool(id) && /^hives_purge/.test(id),
|
|
21
|
+
readOnlyHint: op.method === 'GET', destructiveHint: id === 'hives_stop_deployment' || op.method === 'DELETE' || isHivesResourceTool(id) && /^hives_purge/.test(id),
|
|
22
22
|
idempotentHint: isHivesResourceTool(id) && op.method !== 'GET' ? false : ['GET', 'PUT', 'DELETE'].includes(op.method) || id === BEACONS_PROVISION_OPERATION || op.path === '/v1/iam/runner/self-execution-grant', openWorldHint: true,
|
|
23
23
|
});
|
|
24
24
|
/** Curated tools: one per operation tagged x-mcp in the merged spec. */
|
|
@@ -102,7 +102,7 @@ async function invoke(genesis, id, args, signal) {
|
|
|
102
102
|
});
|
|
103
103
|
}
|
|
104
104
|
else
|
|
105
|
-
r = op.service === 'hives'
|
|
105
|
+
r = (op.service === 'hives' || op.service === 'blinds' || id === 'relays_getEnrollment' || id === 'relays_enroll')
|
|
106
106
|
? await genesis.request(id, args, { signal })
|
|
107
107
|
: await genesis.request(id, args);
|
|
108
108
|
return text(r === undefined ? { ok: true } : r);
|
|
@@ -125,5 +125,5 @@ export async function callTool(opts, name, args = {}, signal) {
|
|
|
125
125
|
return text(`Unknown operation "${id}". Use genesis_search_tools to find one.`, true);
|
|
126
126
|
const hives = op.service === 'hives';
|
|
127
127
|
const genesis = new Genesis(hives ? { ...opts, fetch: createHivesNodeTransport(opts, signal) } : opts);
|
|
128
|
-
return invoke(genesis, id, input, hives || isFleetsLifecycleTool(id) ? signal : undefined);
|
|
128
|
+
return invoke(genesis, id, input, hives || op.service === 'blinds' || id === 'relays_getEnrollment' || id === 'relays_enroll' || isFleetsLifecycleTool(id) ? signal : undefined);
|
|
129
129
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lifesi/genesis-mcp",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.5",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/l1felabs/genesis-api.git",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"@modelcontextprotocol/sdk": "^1.32.1",
|
|
20
20
|
"undici": "6.29.0",
|
|
21
|
-
"@lifesi/genesis": "0.1.
|
|
21
|
+
"@lifesi/genesis": "0.1.5"
|
|
22
22
|
},
|
|
23
23
|
"scripts": {
|
|
24
24
|
"build": "tsc -p tsconfig.json"
|