@productbrain/mcp 0.0.1-beta.16 → 0.0.1-beta.17

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.
@@ -310,16 +310,18 @@ ${formatted}` }]
310
310
  inputSchema: {
311
311
  from: z.string().describe("Source entry ID, e.g. 'T-SUPPLIER'"),
312
312
  to: z.string().describe("Target entry ID, e.g. 'BR-001'"),
313
- type: z.string().describe("Relation type \u2014 use a recommended type or any descriptive string")
313
+ type: z.string().describe("Relation type \u2014 use a recommended type or any descriptive string"),
314
+ score: z.number().optional().describe("Suggestion score from suggest-links (improves feedback for weight tuning)")
314
315
  },
315
316
  annotations: { destructiveHint: false }
316
317
  },
317
- async ({ from, to, type }) => {
318
+ async ({ from, to, type, score }) => {
318
319
  requireWriteAccess();
319
320
  const result = await mcpMutation("chain.createEntryRelation", {
320
321
  fromEntryId: from,
321
322
  toEntryId: to,
322
- type
323
+ type,
324
+ metadata: score != null ? { suggestionScore: score } : void 0
323
325
  });
324
326
  await recordSessionActivity({ relationCreated: result?.status !== "proposal_created" });
325
327
  const wsCtx = await getWorkspaceContext();
@@ -1471,11 +1473,13 @@ function registerHealthTools(server) {
1471
1473
  lines.push("---");
1472
1474
  lines.push("_Warning: Could not mark session as oriented. Write tools may be restricted._");
1473
1475
  }
1474
- mcpMutation("chain.recordSessionSignal", {
1476
+ await mcpMutation("chain.recordSessionSignal", {
1475
1477
  sessionId: agentSessionId,
1476
1478
  signalType: "immediate_context_load",
1477
1479
  metadata: { source: "orient" }
1478
- }).catch(() => {
1480
+ }).catch((err) => {
1481
+ process.stderr.write(`[MCP] recordSessionSignal failed: ${err.message}
1482
+ `);
1479
1483
  });
1480
1484
  } else {
1481
1485
  lines.push("---");
@@ -4549,4 +4553,4 @@ export {
4549
4553
  SERVER_VERSION,
4550
4554
  createProductBrainServer
4551
4555
  };
4552
- //# sourceMappingURL=chunk-5V4JXM4G.js.map
4556
+ //# sourceMappingURL=chunk-REFAR36Z.js.map