@productbrain/mcp 0.0.1-beta.8727 → 0.0.1-beta.8737
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/{chunk-GD53V2VD.js → chunk-4GJ3KH6Q.js} +2 -26
- package/dist/chunk-4GJ3KH6Q.js.map +1 -0
- package/dist/{chunk-2UJDIWEX.js → chunk-7GE3P7XW.js} +1 -18
- package/dist/chunk-7GE3P7XW.js.map +1 -0
- package/dist/cli/index.js +1 -1
- package/dist/http.js +2 -2
- package/dist/index.js +2 -2
- package/dist/{setup-SF4Z3IBZ.js → setup-PF2ZDPZC.js} +2 -2
- package/package.json +1 -1
- package/dist/chunk-2UJDIWEX.js.map +0 -1
- package/dist/chunk-GD53V2VD.js.map +0 -1
- /package/dist/{setup-SF4Z3IBZ.js.map → setup-PF2ZDPZC.js.map} +0 -0
|
@@ -32,7 +32,6 @@ import {
|
|
|
32
32
|
trackCaptureClassifierFallback,
|
|
33
33
|
trackCaptureContractMiss,
|
|
34
34
|
trackCaptureQualityHints,
|
|
35
|
-
trackCaptureRelationSuggestions,
|
|
36
35
|
trackChainEntryCommitted,
|
|
37
36
|
trackClassifierDivergence,
|
|
38
37
|
trackCollectionClassified,
|
|
@@ -44,7 +43,7 @@ import {
|
|
|
44
43
|
trackSessionCaptureRate,
|
|
45
44
|
trackZeroCaptureAuditFired,
|
|
46
45
|
validateCallerSession
|
|
47
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-7GE3P7XW.js";
|
|
48
47
|
|
|
49
48
|
// src/server.ts
|
|
50
49
|
import { McpServer as McpServer2 } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
@@ -1667,7 +1666,6 @@ var captureSuccessOutputSchema = z4.object({
|
|
|
1667
1666
|
// breaking output-contract change. The server verdict stays as `qualityVerdict`.
|
|
1668
1667
|
qualityVerdict: z4.record(z4.unknown()).optional(),
|
|
1669
1668
|
qualityHints: z4.array(z4.record(z4.unknown())).optional(),
|
|
1670
|
-
relationSuggestions: z4.array(z4.record(z4.unknown())).optional(),
|
|
1671
1669
|
groundingReport: captureSinglePreviewOutputSchema.shape.groundingReport.optional(),
|
|
1672
1670
|
classifier: captureClassifierSchema.optional(),
|
|
1673
1671
|
studioUrl: z4.string().optional(),
|
|
@@ -1978,7 +1976,6 @@ ${groundingReport.duplicates.map((d) => `- **${d.entryId}** ${d.name} [${d.colle
|
|
|
1978
1976
|
let internalId;
|
|
1979
1977
|
let normalizationMeta;
|
|
1980
1978
|
let formativeHints = [];
|
|
1981
|
-
let relationSuggestionsFromCreate = [];
|
|
1982
1979
|
let coachingFromCreate;
|
|
1983
1980
|
let wasAutoCommittedServerSide = false;
|
|
1984
1981
|
let spineFloor;
|
|
@@ -2077,7 +2074,6 @@ No DB writes \u2014 call without \`preview:true\` to capture for real.${result2.
|
|
|
2077
2074
|
finalEntryId = created.entryId;
|
|
2078
2075
|
entryWarnings.push(...created.warnings ?? []);
|
|
2079
2076
|
normalizationMeta = created.normalization;
|
|
2080
|
-
relationSuggestionsFromCreate = created.relationSuggestions ?? [];
|
|
2081
2077
|
formativeHints = created.qualityHints ?? [];
|
|
2082
2078
|
coachingFromCreate = created.coaching;
|
|
2083
2079
|
resolveGapsForEntry(name, created.entryId);
|
|
@@ -2434,14 +2430,6 @@ Use \`entries action=get\` to inspect the existing entry, or \`entries action=up
|
|
|
2434
2430
|
}
|
|
2435
2431
|
lines.push(`_These hints are advisory \u2014 your entry was captured. Use \`entries action=update entryId="${finalEntryId}"\` to address them._`);
|
|
2436
2432
|
}
|
|
2437
|
-
if (relationSuggestionsFromCreate.length > 0) {
|
|
2438
|
-
lines.push("");
|
|
2439
|
-
lines.push("## Suggested Relations (advisory)");
|
|
2440
|
-
for (const rs of relationSuggestionsFromCreate) {
|
|
2441
|
-
lines.push(`- **${rs.relationType}** \u2192 ${rs.targetEntryId} "${rs.targetName}" (confidence: ${rs.confidence})`);
|
|
2442
|
-
}
|
|
2443
|
-
lines.push(`_Create with: \`relations action=create from="${finalEntryId}" to="TARGET-ID" type="TYPE"\`_`);
|
|
2444
|
-
}
|
|
2445
2433
|
if (formativeHints.length > 0) {
|
|
2446
2434
|
trackCaptureQualityHints(wsCtx.workspaceId, {
|
|
2447
2435
|
collection: resolvedCollection,
|
|
@@ -2449,16 +2437,6 @@ Use \`entries action=get\` to inspect the existing entry, or \`entries action=up
|
|
|
2449
2437
|
hint_fields: formativeHints.map((h) => h.field)
|
|
2450
2438
|
});
|
|
2451
2439
|
}
|
|
2452
|
-
if (relationSuggestionsFromCreate.length > 0) {
|
|
2453
|
-
trackCaptureRelationSuggestions(wsCtx.workspaceId, {
|
|
2454
|
-
collection: resolvedCollection,
|
|
2455
|
-
suggestion_count: relationSuggestionsFromCreate.length,
|
|
2456
|
-
relation_types: relationSuggestionsFromCreate.map((rs) => rs.relationType),
|
|
2457
|
-
avg_confidence: Math.round(
|
|
2458
|
-
relationSuggestionsFromCreate.reduce((sum, rs) => sum + rs.confidence, 0) / relationSuggestionsFromCreate.length
|
|
2459
|
-
)
|
|
2460
|
-
});
|
|
2461
|
-
}
|
|
2462
2440
|
const isWorkPackageOrBetCapture = isWorkPackageCapture || resolvedCK === "bet";
|
|
2463
2441
|
const isBetOrGoal = isWorkPackageOrBetCapture || resolvedCK === "goal";
|
|
2464
2442
|
const hasStrategyLink = linksCreated.some((l) => l.targetCollection === "strategy");
|
|
@@ -2584,8 +2562,6 @@ Use \`entries action=get\` to inspect the existing entry, or \`entries action=up
|
|
|
2584
2562
|
expectedFields,
|
|
2585
2563
|
// BET-272 S3: Advisory quality hints — always included (empty array when all criteria pass)
|
|
2586
2564
|
qualityHints: formativeHints,
|
|
2587
|
-
// BET-272 S5: Advisory relation suggestions from graph (BR-144, STD-147)
|
|
2588
|
-
relationSuggestions: relationSuggestionsFromCreate,
|
|
2589
2565
|
// WP-745 TASK-160 (PR #901 review): the machine-readable projection — was reaching the human text only.
|
|
2590
2566
|
...spineFloor && { spineFloor },
|
|
2591
2567
|
// WP-318 S2: Pre-write grounding report — always included (empty arrays when no suggestions)
|
|
@@ -14167,4 +14143,4 @@ export {
|
|
|
14167
14143
|
createProductBrainServer,
|
|
14168
14144
|
initFeatureFlags
|
|
14169
14145
|
};
|
|
14170
|
-
//# sourceMappingURL=chunk-
|
|
14146
|
+
//# sourceMappingURL=chunk-4GJ3KH6Q.js.map
|