@productbrain/mcp 0.0.1-beta.2236 → 0.0.1-beta.2250
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.
|
@@ -8530,6 +8530,19 @@ var orientSchema = z15.object({
|
|
|
8530
8530
|
"For 'task': natural-language task description for task-scoped context. For 'start': what you're about to work on. When provided to 'task', orient returns scored, relevant entries for the task."
|
|
8531
8531
|
),
|
|
8532
8532
|
scope: z15.string().max(200).optional().describe("For 'task': optional domain scope to filter governance to entries relevant for this domain. Forwarded to Convex for workspace-specific validation."),
|
|
8533
|
+
// WP-486 Slice 1 (FEAT-1371, TEN-2724): the startup-signal envelope `resolveStartupDomain`
|
|
8534
|
+
// already consumes (`convex/agentKnowledge/startupResolver.ts:344-379`) but this tool never
|
|
8535
|
+
// sent. Nested to match the server's `StartupResolutionSignals` shape exactly (not a flat
|
|
8536
|
+
// field set) — the caller (the agent, which may have its own git/session context from prior
|
|
8537
|
+
// tool calls) supplies whichever fields it knows; every field is optional and independently
|
|
8538
|
+
// sanitized server-side (`convex/agentKnowledge/startupResolutionSignals.ts`).
|
|
8539
|
+
startupSignals: z15.object({
|
|
8540
|
+
changedPaths: z15.array(z15.string()).max(25).optional().describe("Paths changed in the current working tree, if known (e.g. from a prior git status/diff tool call)."),
|
|
8541
|
+
reviewedArtifactRefs: z15.array(z15.string()).max(25).optional().describe("Chain entry IDs the caller has already reviewed this session, if tracked."),
|
|
8542
|
+
branchName: z15.string().max(120).optional().describe("Current git branch name, if known."),
|
|
8543
|
+
worktreeName: z15.string().max(120).optional().describe("Current worktree/directory name, if known.")
|
|
8544
|
+
}).optional().describe("For 'task': best-effort startup signals for domain resolution \u2014 changedPaths/reviewedArtifactRefs/branchName/worktreeName. All optional; omit fields you don't know."),
|
|
8545
|
+
invocationPath: z15.enum(["session-start", "session-close", "manual-orient", "handshake", "unknown"]).optional().describe("For 'task': how this orient was invoked. Defaults to 'manual-orient' (the direct `orient task=...` call shape) when omitted."),
|
|
8533
8546
|
confirmedEntryCount: z15.number().int().min(0).optional().describe(
|
|
8534
8547
|
"For 'record-activation': confirmed-entry count from the Phase 4 capture loop. The mutation enforces >=10."
|
|
8535
8548
|
),
|
|
@@ -8549,7 +8562,16 @@ var orientTaskVariant = z15.object({
|
|
|
8549
8562
|
mode: z15.enum(["full", "brief"]).optional().default("full"),
|
|
8550
8563
|
tier: z15.enum(["summary", "standard", "full"]).optional(),
|
|
8551
8564
|
task: z15.string().max(2e3).optional(),
|
|
8552
|
-
scope: z15.string().max(200).optional()
|
|
8565
|
+
scope: z15.string().max(200).optional(),
|
|
8566
|
+
// WP-486 Slice 1 (FEAT-1371) — mirrors orientSchema's top-level declaration above; see its
|
|
8567
|
+
// doc comment for the shape rationale.
|
|
8568
|
+
startupSignals: z15.object({
|
|
8569
|
+
changedPaths: z15.array(z15.string()).max(25).optional(),
|
|
8570
|
+
reviewedArtifactRefs: z15.array(z15.string()).max(25).optional(),
|
|
8571
|
+
branchName: z15.string().max(120).optional(),
|
|
8572
|
+
worktreeName: z15.string().max(120).optional()
|
|
8573
|
+
}).optional(),
|
|
8574
|
+
invocationPath: z15.enum(["session-start", "session-close", "manual-orient", "handshake", "unknown"]).optional()
|
|
8553
8575
|
});
|
|
8554
8576
|
var orientRecordActivationVariant = z15.object({
|
|
8555
8577
|
action: z15.literal("record-activation"),
|
|
@@ -8592,7 +8614,14 @@ function taskGroundingWarningLines(task, hasTaskGrounding = false) {
|
|
|
8592
8614
|
function registerOrientTool(server) {
|
|
8593
8615
|
const orientHandlers = {
|
|
8594
8616
|
start: (data) => handleStartPb({ task: data.task }),
|
|
8595
|
-
task: (data) => _handleOrient({
|
|
8617
|
+
task: (data) => _handleOrient({
|
|
8618
|
+
mode: data.mode,
|
|
8619
|
+
tier: data.tier,
|
|
8620
|
+
task: data.task,
|
|
8621
|
+
scope: data.scope,
|
|
8622
|
+
startupSignals: data.startupSignals,
|
|
8623
|
+
invocationPath: data.invocationPath
|
|
8624
|
+
}),
|
|
8596
8625
|
"record-activation": (data) => handleRecordActivation({
|
|
8597
8626
|
confirmedEntryCount: data.confirmedEntryCount,
|
|
8598
8627
|
entriesAcrossCollections: data.entriesAcrossCollections,
|
|
@@ -8619,7 +8648,7 @@ function registerOrientTool(server) {
|
|
|
8619
8648
|
})
|
|
8620
8649
|
);
|
|
8621
8650
|
}
|
|
8622
|
-
async function _handleOrient({ mode = "full", tier, task, scope }) {
|
|
8651
|
+
async function _handleOrient({ mode = "full", tier, task, scope, startupSignals, invocationPath }) {
|
|
8623
8652
|
const errors = [];
|
|
8624
8653
|
const callTier = tier ?? (mode === "brief" ? "summary" : void 0);
|
|
8625
8654
|
if (scope && !task) {
|
|
@@ -8657,6 +8686,12 @@ async function _handleOrient({ mode = "full", tier, task, scope }) {
|
|
|
8657
8686
|
const orientArgs = {};
|
|
8658
8687
|
if (task) orientArgs.task = task;
|
|
8659
8688
|
if (scope) orientArgs.scope = scope;
|
|
8689
|
+
if (startupSignals && Object.keys(startupSignals).length > 0) orientArgs.startupSignals = startupSignals;
|
|
8690
|
+
if (invocationPath) {
|
|
8691
|
+
orientArgs.invocationPath = invocationPath;
|
|
8692
|
+
} else if (task) {
|
|
8693
|
+
orientArgs.invocationPath = "manual-orient";
|
|
8694
|
+
}
|
|
8660
8695
|
if (callTier) orientArgs.tier = callTier;
|
|
8661
8696
|
orientArgs.renderMode = "json";
|
|
8662
8697
|
if (agentSessionId) orientArgs.sessionId = agentSessionId;
|
|
@@ -15319,4 +15354,4 @@ export {
|
|
|
15319
15354
|
createProductBrainServer,
|
|
15320
15355
|
initFeatureFlags
|
|
15321
15356
|
};
|
|
15322
|
-
//# sourceMappingURL=chunk-
|
|
15357
|
+
//# sourceMappingURL=chunk-YV2O2QGE.js.map
|