@burdenoff/mcp-libs 2026.1031.1 → 2026.1031.2
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/modules/cosmicintersection/index.cjs +49 -3
- package/dist/modules/cosmicintersection/index.cjs.map +1 -1
- package/dist/modules/cosmicintersection/index.js +49 -3
- package/dist/modules/cosmicintersection/index.js.map +1 -1
- package/dist/modules/cosmicintersection/operations.d.ts +5 -4
- package/package.json +1 -1
|
@@ -85,8 +85,8 @@ var PIPELINE_FIELDS = `
|
|
|
85
85
|
tags createdAt updatedAt workspaceId
|
|
86
86
|
`;
|
|
87
87
|
var STEP_FIELDS = `
|
|
88
|
-
id runId name kind status position inputs outputs logsRef
|
|
89
|
-
startedAt finishedAt errorMessage createdAt updatedAt workspaceId
|
|
88
|
+
id runId name kind status position inputs outputs producedDatasetIds logsRef
|
|
89
|
+
durationMs startedAt finishedAt errorMessage createdAt updatedAt workspaceId
|
|
90
90
|
`;
|
|
91
91
|
var RUN_FIELDS = `
|
|
92
92
|
id pipelineId runNumber status params metrics datasetId triggeredBy
|
|
@@ -324,6 +324,17 @@ var ADD_RUN_STEP = `
|
|
|
324
324
|
}
|
|
325
325
|
}
|
|
326
326
|
`;
|
|
327
|
+
var COMPLETE_RUN_STEP = `
|
|
328
|
+
mutation CosmicintersectionCompleteRunStep(
|
|
329
|
+
$runId: ID!
|
|
330
|
+
$stepId: ID!
|
|
331
|
+
$input: CosCompleteRunStepInput!
|
|
332
|
+
) {
|
|
333
|
+
cosCompleteRunStep(runId: $runId, stepId: $stepId, input: $input) {
|
|
334
|
+
${STEP_FIELDS}
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
`;
|
|
327
338
|
var GET_NOTEBOOK = `
|
|
328
339
|
query CosmicintersectionGetNotebook($id: ID!) {
|
|
329
340
|
cosNotebook(id: $id) {
|
|
@@ -1133,6 +1144,7 @@ function registerPipelineTools(server, ctx, track) {
|
|
|
1133
1144
|
}
|
|
1134
1145
|
);
|
|
1135
1146
|
}
|
|
1147
|
+
var CosStepCompletionStatusEnum = zod.z.enum(["SUCCEEDED", "FAILED", "CANCELLED"]);
|
|
1136
1148
|
function registerRunTools(server, ctx, track) {
|
|
1137
1149
|
server.registerTool(
|
|
1138
1150
|
track(mcpToolName(ctx.productName, "runs_get")),
|
|
@@ -1283,6 +1295,40 @@ function registerRunTools(server, ctx, track) {
|
|
|
1283
1295
|
}
|
|
1284
1296
|
}
|
|
1285
1297
|
);
|
|
1298
|
+
server.registerTool(
|
|
1299
|
+
track(mcpToolName(ctx.productName, "runs_steps_complete")),
|
|
1300
|
+
{
|
|
1301
|
+
title: "Complete Run Step",
|
|
1302
|
+
description: "Finish a run step with its status, outputs, error and the datasets it produced. producedDatasetIds must be datasets in this workspace you can read (else NOT_FOUND, nothing changes); they are stored as outputs.producedDatasetIds, the datasets are marked lineageCaptured, and catalog search lineage then shows the run as PRODUCED_BY. Completing a finished step returns CONFLICT.",
|
|
1303
|
+
inputSchema: {
|
|
1304
|
+
runId: zod.z.string().describe("Run ID"),
|
|
1305
|
+
stepId: zod.z.string().describe("Step ID"),
|
|
1306
|
+
status: CosStepCompletionStatusEnum.describe("Final step status"),
|
|
1307
|
+
outputs: JsonObject.optional().describe(
|
|
1308
|
+
"Step outputs JSON (e.g. rowsIn/rowsOut/anomaliesFlagged/warnings)"
|
|
1309
|
+
),
|
|
1310
|
+
producedDatasetIds: zod.z.array(zod.z.string().min(1)).max(100).optional().describe("Datasets this step wrote (at most 100)"),
|
|
1311
|
+
errorMessage: zod.z.string().optional().describe("Error message for a failed step"),
|
|
1312
|
+
logsRef: zod.z.string().optional().describe("Reference to the step logs (e.g. an object-store URI)")
|
|
1313
|
+
}
|
|
1314
|
+
},
|
|
1315
|
+
async ({ runId, stepId, status, outputs, producedDatasetIds, errorMessage, logsRef }) => {
|
|
1316
|
+
try {
|
|
1317
|
+
const input = { status };
|
|
1318
|
+
if (outputs !== void 0) input.outputs = outputs;
|
|
1319
|
+
if (producedDatasetIds !== void 0) input.producedDatasetIds = producedDatasetIds;
|
|
1320
|
+
if (errorMessage !== void 0) input.errorMessage = errorMessage;
|
|
1321
|
+
if (logsRef !== void 0) input.logsRef = logsRef;
|
|
1322
|
+
const data = await ctx.gql.workspace.request(COMPLETE_RUN_STEP, { runId, stepId, input });
|
|
1323
|
+
return jsonResult(data.cosCompleteRunStep);
|
|
1324
|
+
} catch (error) {
|
|
1325
|
+
ctx.logger.error("cosmicintersection runs_steps_complete failed", { error: String(error) });
|
|
1326
|
+
return errorResult(
|
|
1327
|
+
`Failed to complete run step: ${error instanceof Error ? error.message : String(error)}`
|
|
1328
|
+
);
|
|
1329
|
+
}
|
|
1330
|
+
}
|
|
1331
|
+
);
|
|
1286
1332
|
}
|
|
1287
1333
|
function registerNotebookTools(server, ctx, track) {
|
|
1288
1334
|
server.registerTool(
|
|
@@ -1977,7 +2023,7 @@ Show results at each step and confirm before publishing.`
|
|
|
1977
2023
|
text: `Run a reproducible-research publication workflow. ${notebookNote}
|
|
1978
2024
|
|
|
1979
2025
|
1. **Pipeline**: Use ${p}_pipelines_list / ${p}_pipelines_create to set up the processing pipeline (definition + trigger).
|
|
1980
|
-
2. **Run**: Use ${p}_runs_start to queue a run, ${p}_runs_steps_add to append steps, and ${p}_runs_transition to advance it (QUEUED \u2192 RUNNING \u2192 SUCCEEDED).
|
|
2026
|
+
2. **Run**: Use ${p}_runs_start to queue a run, ${p}_runs_steps_add to append steps, ${p}_runs_steps_complete to finish each step (pass producedDatasetIds for the datasets it wrote, so search lineage shows the run as PRODUCED_BY), and ${p}_runs_transition to advance it (QUEUED \u2192 RUNNING \u2192 SUCCEEDED).
|
|
1981
2027
|
3. **Analyze**: Use ${p}_analyses_run against the resulting dataset/notebook, then ${p}_analyses_complete with the results and an output File.
|
|
1982
2028
|
4. **Release**: Use ${p}_releases_create to bundle datasets + notebook, then ${p}_releases_publish to stamp a DOI.
|
|
1983
2029
|
5. **(Optional) Share Access**: Use ${p}_grants_grant to give collaborators scoped access to the underlying datasets.
|