@lucern/mcp 0.3.0-alpha.14 → 0.3.0-alpha.16

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/gateway.js CHANGED
@@ -782,6 +782,7 @@ defineTable({
782
782
  shape: z.object({
783
783
  "tenantId": idOf("tenants"),
784
784
  "workspaceId": idOf("workspaces").optional(),
785
+ "environment": z.enum(["dev", "staging", "prod"]).optional(),
785
786
  "keyPrefix": z.enum(["luc", "stk"]),
786
787
  "keyHash": z.string(),
787
788
  "keyHint": z.string(),
@@ -5929,6 +5930,7 @@ var INFISICAL_TENANT_SOFTWARE_SYSTEMS = [
5929
5930
  vercelProjectName: "ai-chatbot-diao",
5930
5931
  vercelTeamId: "team_mZBKwvXSSu7qxrWdg2go29sK",
5931
5932
  vercelProjectId: "prj_PihFw8kohSSw14nZs9YQV3xVo517",
5933
+ vercelWriterTokenEnv: "STACK_VERCEL_TOKEN",
5932
5934
  repository: {
5933
5935
  owner: "stack-vc",
5934
5936
  name: "front-end"
@@ -5949,6 +5951,7 @@ var INFISICAL_TENANT_SOFTWARE_SYSTEMS = [
5949
5951
  vercelProjectName: "stackos",
5950
5952
  vercelTeamId: "team_mZBKwvXSSu7qxrWdg2go29sK",
5951
5953
  vercelProjectId: "prj_rXLAL0Z6v9p1fasKbomby6GI7kau",
5954
+ vercelWriterTokenEnv: "STACK_VERCEL_TOKEN",
5952
5955
  repository: {
5953
5956
  owner: "stack-vc",
5954
5957
  name: "stackos"
@@ -5969,6 +5972,7 @@ var INFISICAL_TENANT_SOFTWARE_SYSTEMS = [
5969
5972
  vercelProjectName: "stackos-engineering-graph",
5970
5973
  vercelTeamId: "team_mZBKwvXSSu7qxrWdg2go29sK",
5971
5974
  vercelProjectId: "prj_zAU0Zn9GkbHjHI63dxW4vLpmoqTJ",
5975
+ vercelWriterTokenEnv: "STACK_VERCEL_TOKEN",
5972
5976
  repository: {
5973
5977
  owner: "stack-vc",
5974
5978
  name: "stackos-engineering-graph"
@@ -5989,6 +5993,7 @@ var INFISICAL_TENANT_SOFTWARE_SYSTEMS = [
5989
5993
  vercelProjectName: "lucern-graph",
5990
5994
  vercelTeamId: "team_vTHxxs8GAoAFUe6RWMlYt7fY",
5991
5995
  vercelProjectId: "prj_KJ8EKV8vGM5xURpqmwTwmECEGPgQ",
5996
+ vercelWriterTokenEnv: "LUCERN_VERCEL_TOKEN",
5992
5997
  repository: {
5993
5998
  owner: "LucernAI",
5994
5999
  name: "lucern-graph"
@@ -6934,7 +6939,7 @@ function compactRecord2(input) {
6934
6939
  Object.entries(input).filter(([, value]) => value !== void 0)
6935
6940
  );
6936
6941
  }
6937
- var listBeliefsProjection = defineProjection({
6942
+ defineProjection({
6938
6943
  contractName: "list_beliefs",
6939
6944
  inputSchema: listBeliefsInputSchema,
6940
6945
  project: (input) => compactRecord2({
@@ -12238,11 +12243,8 @@ var identityContracts = [
12238
12243
  sdkNamespace: "identity",
12239
12244
  sdkMethod: "whoami",
12240
12245
  summary: "Describe the current gateway principal.",
12241
- convex: {
12242
- module: "identity",
12243
- functionName: "whoami",
12244
- kind: "query",
12245
- inputProjection: withPrincipal
12246
+ gateway: {
12247
+ handler: "identity.whoami"
12246
12248
  }
12247
12249
  }),
12248
12250
  surfaceContract({
@@ -12262,7 +12264,7 @@ var identityContracts = [
12262
12264
  providerProjectId: z.string().min(1).optional()
12263
12265
  }),
12264
12266
  convex: {
12265
- module: "identity",
12267
+ module: "platform",
12266
12268
  functionName: "resolveInteractivePrincipal",
12267
12269
  kind: "query"
12268
12270
  }
@@ -12346,15 +12348,6 @@ var beliefLookupInput = (input) => compactRecord4({
12346
12348
  var beliefNodeInput = (input) => compactRecord4({
12347
12349
  nodeId: input.nodeId ?? input.id ?? input.beliefId
12348
12350
  });
12349
- var beliefTopicInput = (input) => {
12350
- const parsed = listBeliefsProjection.inputSchema.safeParse(input);
12351
- if (!parsed.success) {
12352
- throw new Error(
12353
- `list_beliefs projection input rejected: ${parsed.error.message}`
12354
- );
12355
- }
12356
- return compactRecord4(listBeliefsProjection.project(parsed.data));
12357
- };
12358
12351
  var createBeliefInput = (input, context) => {
12359
12352
  return withUserId(
12360
12353
  compactRecord4({
@@ -12443,11 +12436,8 @@ var beliefsContracts = [
12443
12436
  sdkNamespace: "beliefs",
12444
12437
  sdkMethod: "listBeliefs",
12445
12438
  summary: "List beliefs for a topic.",
12446
- convex: {
12447
- module: "beliefs",
12448
- functionName: "getByTopic",
12449
- kind: "query",
12450
- inputProjection: beliefTopicInput
12439
+ gateway: {
12440
+ handler: "beliefs.list"
12451
12441
  },
12452
12442
  args: listBeliefsInputSchema
12453
12443
  }),
@@ -12632,12 +12622,6 @@ var evidenceIdInput = (input) => compactRecord4({
12632
12622
  insightId: input.insightId,
12633
12623
  nodeId: input.nodeId ?? input.id ?? input.evidenceId
12634
12624
  });
12635
- var evidenceTopicInput = (input) => compactRecord4({
12636
- topicId: input.topicId,
12637
- status: input.status,
12638
- userId: input.userId,
12639
- limit: input.limit
12640
- });
12641
12625
  var createEvidenceInput = (input, context) => {
12642
12626
  const parsed = createEvidenceProjection.inputSchema.safeParse(input);
12643
12627
  if (!parsed.success) {
@@ -12768,11 +12752,8 @@ var evidenceContracts = [
12768
12752
  sdkNamespace: "evidence",
12769
12753
  sdkMethod: "listEvidence",
12770
12754
  summary: "List evidence for a topic.",
12771
- convex: {
12772
- module: "evidence",
12773
- functionName: "getByTopic",
12774
- kind: "query",
12775
- inputProjection: evidenceTopicInput
12755
+ gateway: {
12756
+ handler: "evidence.list"
12776
12757
  }
12777
12758
  }),
12778
12759
  surfaceContract({
@@ -13007,11 +12988,8 @@ var questionsContracts = [
13007
12988
  sdkNamespace: "questions",
13008
12989
  sdkMethod: "listQuestions",
13009
12990
  summary: "List questions for a topic.",
13010
- convex: {
13011
- module: "questions",
13012
- functionName: "getByTopic",
13013
- kind: "query",
13014
- inputProjection: questionTopicInput
12991
+ gateway: {
12992
+ handler: "questions.list"
13015
12993
  }
13016
12994
  }),
13017
12995
  surfaceContract({
@@ -14514,6 +14492,19 @@ var createTaskArgs = z.object({
14514
14492
  tags: z.array(z.string()).optional().describe("Free-form tags."),
14515
14493
  metadata: z.record(z.unknown()).optional().describe("Structured task metadata for handoff context and routing hints.")
14516
14494
  });
14495
+ var updateTaskArgs = z.object({
14496
+ taskId: z.string().describe("Task to update."),
14497
+ title: z.string().optional().describe("Updated task title."),
14498
+ description: z.string().optional().describe("Updated task description."),
14499
+ priority: taskPrioritySchema.optional().describe("Updated priority."),
14500
+ status: taskStatusSchema2.optional().describe("Updated status."),
14501
+ linkedWorktreeId: z.string().optional().describe("Worktree this task belongs to."),
14502
+ linkedBeliefId: z.string().optional().describe("Belief this task supports."),
14503
+ linkedQuestionId: z.string().optional().describe("Question this task addresses."),
14504
+ assigneeId: z.string().optional().describe("Principal assigned to the task."),
14505
+ blockedReason: z.string().optional().describe("Reason the task is blocked or deferred."),
14506
+ metadata: z.record(z.unknown()).optional().describe("Structured task metadata for handoff context and routing hints.")
14507
+ });
14517
14508
  var createTaskInput = (input) => compactRecord4({
14518
14509
  title: input.title,
14519
14510
  topicId: input.topicId,
@@ -14600,7 +14591,8 @@ var tasksContracts = [
14600
14591
  kind: "mutation",
14601
14592
  inputProjection: taskInput
14602
14593
  },
14603
- gateway: { handler: "tasks.update" }
14594
+ gateway: { handler: "tasks.update" },
14595
+ args: updateTaskArgs
14604
14596
  }),
14605
14597
  surfaceContract({
14606
14598
  name: "complete_task",
@@ -23028,6 +23020,8 @@ function normalizeTaskRecord(value) {
23028
23020
  status: normalizeTaskStatus(record.status ?? metadata.status),
23029
23021
  priority: normalizeTaskPriority(record.priority ?? metadata.priority),
23030
23022
  taskType: normalizeTaskType(record.taskType ?? metadata.taskType),
23023
+ ...readString16(record.assigneeId) ? { assigneeId: readString16(record.assigneeId) } : {},
23024
+ ...readString16(record.blockedReason) ? { blockedReason: readString16(record.blockedReason) } : {},
23031
23025
  ...readString16(record.linkedBeliefId) ? { linkedBeliefId: readString16(record.linkedBeliefId) } : {},
23032
23026
  ...readString16(record.linkedQuestionId) ? { linkedQuestionId: readString16(record.linkedQuestionId) } : {},
23033
23027
  ...readString16(record.linkedWorktreeId) ? { linkedWorktreeId: readString16(record.linkedWorktreeId) } : {},
@@ -23070,7 +23064,7 @@ async function createTask(deps, input) {
23070
23064
  }
23071
23065
  async function updateTask(deps, input) {
23072
23066
  const taskRawId = normalizeRequiredString9(input.id, "id");
23073
- const hasPatchField = input.title !== void 0 || input.description !== void 0 || input.priority !== void 0 || input.status !== void 0 || input.linkedBeliefId !== void 0 || input.linkedQuestionId !== void 0 || input.linkedWorktreeId !== void 0 || input.metadata !== void 0;
23067
+ const hasPatchField = input.title !== void 0 || input.description !== void 0 || input.priority !== void 0 || input.status !== void 0 || input.assigneeId !== void 0 || input.blockedReason !== void 0 || input.linkedBeliefId !== void 0 || input.linkedQuestionId !== void 0 || input.linkedWorktreeId !== void 0 || input.metadata !== void 0;
23074
23068
  if (hasPatchField) {
23075
23069
  await deps.updateTask({
23076
23070
  taskRawId,
@@ -23078,6 +23072,8 @@ async function updateTask(deps, input) {
23078
23072
  ...input.description !== void 0 ? { description: readString16(input.description) } : {},
23079
23073
  ...input.priority !== void 0 ? { priority: normalizeTaskPriority(input.priority) } : {},
23080
23074
  ...input.status !== void 0 ? { status: normalizeTaskStatus(input.status) } : {},
23075
+ ...input.assigneeId !== void 0 ? { assigneeId: readString16(input.assigneeId) } : {},
23076
+ ...input.blockedReason !== void 0 ? { blockedReason: readString16(input.blockedReason) } : {},
23081
23077
  ...input.linkedBeliefId !== void 0 ? { linkedBeliefId: readString16(input.linkedBeliefId) } : {},
23082
23078
  ...input.linkedQuestionId !== void 0 ? { linkedQuestionId: readString16(input.linkedQuestionId) } : {},
23083
23079
  ...input.linkedWorktreeId !== void 0 ? { linkedWorktreeId: readString16(input.linkedWorktreeId) } : {},
@@ -23272,6 +23268,8 @@ function createGatewayTasksPort(authContext, options) {
23272
23268
  ...input.description !== void 0 ? { description: input.description } : {},
23273
23269
  ...input.priority !== void 0 ? { priority: input.priority } : {},
23274
23270
  ...input.status !== void 0 ? { status: input.status } : {},
23271
+ ...input.assigneeId !== void 0 ? { assigneeId: input.assigneeId } : {},
23272
+ ...input.blockedReason !== void 0 ? { blockedReason: input.blockedReason } : {},
23275
23273
  ...input.linkedBeliefId !== void 0 ? { linkedBeliefId: input.linkedBeliefId } : {},
23276
23274
  ...input.linkedQuestionId !== void 0 ? { linkedQuestionId: input.linkedQuestionId } : {},
23277
23275
  ...input.linkedWorktreeId !== void 0 ? { linkedWorktreeId: input.linkedWorktreeId } : {},
@@ -29156,6 +29154,8 @@ async function handleTaskUpdate(args) {
29156
29154
  description: readString32(body.description),
29157
29155
  priority: readString32(body.priority),
29158
29156
  status: readString32(body.status),
29157
+ assigneeId: readString32(body.assigneeId),
29158
+ blockedReason: readString32(body.blockedReason),
29159
29159
  linkedBeliefId: readString32(body.linkedBeliefId),
29160
29160
  linkedQuestionId: readString32(body.linkedQuestionId),
29161
29161
  linkedWorktreeId: readString32(body.linkedWorktreeId),