@3ngram/server 1.4.3 → 1.4.4

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.
@@ -35,7 +35,7 @@
35
35
  // rejects) we DERIVE the selector vocabulary from the canonical
36
36
  // {@link briefingSelectorSchema} discriminator and validate the debrief `scope`
37
37
  // against the canonical {@link scopeSchema} before rendering.
38
- import { briefingModeSchema, briefingSelectorSchema, scopeSchema } from '@3ngram/schema';
38
+ import { briefingModeSchema, briefingSelectorSchema, MAX_CONTENT_LENGTH, projectSchema, scopeSchema, } from '@3ngram/schema';
39
39
  import { completable } from '@modelcontextprotocol/server';
40
40
  import { z } from 'zod';
41
41
  import { facetCompleter } from './completions.js';
@@ -130,7 +130,7 @@ const debriefPrompt = definePrompt({
130
130
  name: 'debrief',
131
131
  config: {
132
132
  title: 'Session debrief',
133
- description: 'Close a session cleanly: review what happened, then persist what is worth keeping — decisions, commitments, and follow-ups — by calling the remember TOOL for each, and resolve any completed commitments.',
133
+ description: 'Close a session cleanly: review what happened, then persist what is worth keeping — one typed atom per remember call, content capped — by calling the remember TOOL for each, and resolve any completed commitments.',
134
134
  argsSchema: (ctx) => ({
135
135
  // VALIDATED against the canonical {@link scopeSchema} (kebab-case), the SAME
136
136
  // constraint the `remember` TOOL enforces — so a scope the prompt accepts is
@@ -149,12 +149,19 @@ const debriefPrompt = definePrompt({
149
149
  // CompleteCallback infers its value type from the schema — wrapping the
150
150
  // optional would demand a completer over `string | undefined`.
151
151
  scope: completable(scopeSchema.describe('Optional scope (kebab-case, e.g. work, personal) the session belonged to.'), facetCompleter(ctx, 'scopes')).optional(),
152
+ // Same pattern for project: a NULL project never matches a project-scoped
153
+ // briefing (issue #166 / session-continuity review). Completes from the
154
+ // tenant's live project facets, same as REST GET /memories/facets.
155
+ project: completable(projectSchema.describe('Optional project the session belonged to. Pass it on remember or the memory is invisible to that project briefing.'), facetCompleter(ctx, 'projects')).optional(),
152
156
  }),
153
157
  },
154
- render({ scope }) {
158
+ render({ scope, project }) {
155
159
  const scopeLine = scope === undefined
156
160
  ? 'Tag each memory with the scope the work belonged to.'
157
161
  : `Tag each memory with scope "${scope}".`;
162
+ const projectLine = project === undefined
163
+ ? 'If the work belonged to a project, pass `project` on each remember — a memory with no project never appears in that project briefing.'
164
+ : `Pass project "${project}" on each remember — a memory with no project never appears in that project briefing.`;
158
165
  return userMessage([
159
166
  'Debrief this session before closing. Review the conversation and extract what a',
160
167
  'future session needs, then PERSIST each item by calling the `remember` TOOL:',
@@ -165,6 +172,11 @@ const debriefPrompt = definePrompt({
165
172
  '- Preferences & patterns: conventions or gotchas worth reusing.',
166
173
  '',
167
174
  scopeLine,
175
+ projectLine,
176
+ '',
177
+ `Each remember is ONE typed atom. Content is capped at ${MAX_CONTENT_LENGTH} characters.`,
178
+ 'If a recap would exceed that, split it across several remember calls. Never stuff a',
179
+ 'session transcript into a single memory.',
168
180
  '',
169
181
  'For any commitment COMPLETED this session, call the `resolve` TOOL on its memory id.',
170
182
  'Keep each memory atomic and self-contained; do not persist secrets or raw credentials.',
@@ -1 +1 @@
1
- {"version":3,"file":"prompts.js","sourceRoot":"","sources":["../../src/mcp/prompts.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,qEAAqE;AACrE,EAAE;AACF,gFAAgF;AAChF,8EAA8E;AAC9E,kFAAkF;AAClF,gFAAgF;AAChF,iFAAiF;AACjF,6DAA6D;AAC7D,EAAE;AACF,iFAAiF;AACjF,gFAAgF;AAChF,kFAAkF;AAClF,+EAA+E;AAC/E,gFAAgF;AAChF,gFAAgF;AAChF,2EAA2E;AAC3E,EAAE;AACF,+EAA+E;AAC/E,+EAA+E;AAC/E,gFAAgF;AAChF,6EAA6E;AAC7E,6EAA6E;AAC7E,gBAAgB;AAChB,EAAE;AACF,+EAA+E;AAC/E,2EAA2E;AAC3E,+EAA+E;AAC/E,EAAE;AACF,2EAA2E;AAC3E,gFAAgF;AAChF,kFAAkF;AAClF,gFAAgF;AAChF,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CAAC,CAChC,CAAC,QAAQ,EAAE;SACb,CAAC;KACH;IACD,MAAM,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE;QACvB,MAAM,SAAS,GACb,KAAK,KAAK,SAAS;YACjB,CAAC,CAAC,sDAAsD;YACxD,CAAC,CAAC,+BAA+B,KAAK,IAAI,CAAA;QAC9C,MAAM,WAAW,GACf,OAAO,KAAK,SAAS;YACnB,CAAC,CAAC,uIAAuI;YACzI,CAAC,CAAC,iBAAiB,OAAO,uFAAuF,CAAA;QACrH,OAAO,WAAW,CAChB;YACE,iFAAiF;YACjF,8EAA8E;YAC9E,EAAE;YACF,oFAAoF;YACpF,+FAA+F;YAC/F,wFAAwF;YACxF,iEAAiE;YACjE,EAAE;YACF,SAAS;YACT,WAAW;YACX,EAAE;YACF,yDAAyD,kBAAkB,cAAc;YACzF,qFAAqF;YACrF,0CAA0C;YAC1C,EAAE;YACF,sFAAsF;YACtF,wFAAwF;SACzF,CAAC,IAAI,CAAC,IAAI,CAAC,CACb,CAAA;IACH,CAAC;CACF,CAAC,CAAA;AAEF;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,OAAO,GAAkC,CAAC,cAAc,EAAE,aAAa,CAAC,CAAA;AAErF;;;;;;GAMG;AACH,MAAM,UAAU,eAAe,CAAC,MAAiB,EAAE,GAAgB;IACjE,KAAK,MAAM,MAAM,IAAI,OAAO,EAAE,CAAC;QAC7B,MAAM,CAAC,QAAQ,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC9B,CAAC;AACH,CAAC"}
@@ -15,7 +15,7 @@ import { type ToolContext } from './tools.js';
15
15
  * This is a compression of the JTBD table in docs/concepts/mcp-design.mdx.
16
16
  * Change them together — the doc links back here for exactly that reason.
17
17
  */
18
- export declare const SERVER_INSTRUCTIONS = "3ngram is the user's persistent memory across sessions and tools.\n\nStart a session with `briefing` to load what is already known. Before saying something is not known, not decided, or not recorded, `search` for it (add order: \"chronological\" for an exhaustive listing instead of ranked relevance) \u2014 this corpus outlives the conversation you can see.\n\nMemory is append-only. Never rewrite or delete: use `revise` to supersede a memory that has become wrong, and `resolve` to settle a commitment or blocker. Superseding keeps the old version readable as history.\n\nWrite decisions, commitments, blockers, and stated preferences \u2014 the things that would be expensive to rediscover. Do not write transcript noise, restatements of what the user just said, or anything re-derivable from the code.\n\nScope and project decide what later reads return, so set them when you `remember`: a memory written with no project will not appear in that project's briefing.\n\nWhen a memory states something measurable, pass it as `facts` on the same `remember` call so `get_facts` can read it back without re-parsing prose. Values are text: put the unit in the predicate and keep one measure per fact.";
18
+ export declare const SERVER_INSTRUCTIONS = "3ngram is the user's persistent memory across sessions and tools.\n\nStart a session with `briefing` to load what is already known. Before saying something is not known, not decided, or not recorded, `search` for it (add order: \"chronological\" for an exhaustive listing instead of ranked relevance) \u2014 this corpus outlives the conversation you can see.\n\nMemory is append-only. Never rewrite or delete: use `revise` to supersede a memory that has become wrong, and `resolve` to settle a commitment or blocker. Superseding keeps the old version readable as history.\n\nWrite decisions, commitments, blockers, and stated preferences \u2014 the things that would be expensive to rediscover. Do not write transcript noise, restatements of what the user just said, or anything re-derivable from the code. Each `remember` is one typed atom; content is capped at 2000 characters \u2014 split a longer recap into several calls.\n\nScope and project decide what later reads return, so set them when you `remember`: a memory written with no project will not appear in that project's briefing.\n\nWhen a memory states something measurable, pass it as `facts` on the same `remember` call so `get_facts` can read it back without re-parsing prose. Values are text: put the unit in the predicate and keep one measure per fact.";
19
19
  /**
20
20
  * Tool definitions, prompt definitions, and the discovery advertisement change
21
21
  * only with a server deployment. One hour avoids reconnect refetches without
@@ -5,6 +5,7 @@
5
5
  // request — any instance serves any request and a Railway redeploy is a
6
6
  // non-event. The authenticated tenant + optional embedding gateway are captured
7
7
  // in the handler closure (the per-request context), never stored on the server.
8
+ import { MAX_CONTENT_LENGTH } from '@3ngram/schema';
8
9
  import { McpServer } from '@modelcontextprotocol/server';
9
10
  import { SERVER_VERSION } from '../version.js';
10
11
  import { registerPrompts } from './prompts.js';
@@ -34,7 +35,7 @@ Start a session with \`briefing\` to load what is already known. Before saying s
34
35
 
35
36
  Memory is append-only. Never rewrite or delete: use \`revise\` to supersede a memory that has become wrong, and \`resolve\` to settle a commitment or blocker. Superseding keeps the old version readable as history.
36
37
 
37
- Write decisions, commitments, blockers, and stated preferences — the things that would be expensive to rediscover. Do not write transcript noise, restatements of what the user just said, or anything re-derivable from the code.
38
+ Write decisions, commitments, blockers, and stated preferences — the things that would be expensive to rediscover. Do not write transcript noise, restatements of what the user just said, or anything re-derivable from the code. Each \`remember\` is one typed atom; content is capped at ${MAX_CONTENT_LENGTH} characters — split a longer recap into several calls.
38
39
 
39
40
  Scope and project decide what later reads return, so set them when you \`remember\`: a memory written with no project will not appear in that project's briefing.
40
41
 
@@ -1 +1 @@
1
- {"version":3,"file":"server.js","sourceRoot":"","sources":["../../src/mcp/server.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,6EAA6E;AAC7E,+EAA+E;AAC/E,gFAAgF;AAChF,wEAAwE;AACxE,gFAAgF;AAChF,gFAAgF;AAChF,OAAO,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAA;AACxD,OAAO,EAAE,cAAc,EAAE,MAAM,eAAe,CAAA;AAC9C,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAA;AAC9C,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAA;AAClD,OAAO,EAAE,OAAO,EAAE,KAAK,EAAoB,MAAM,YAAY,CAAA;AAE7D,8EAA8E;AAC9E,uEAAuE;AACvE,MAAM,WAAW,GAAG,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,cAAc,EAAW,CAAA;AAExE;;;;;;;;;;;;;;GAcG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAG;;;;;;;;;;wOAUqM,CAAA;AAExO;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAG,EAAE,GAAG,MAAM,CAAA;AAEnD;;;;;;;;;;GAUG;AACH,MAAM,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;YACtE,qEAAqE;YACrE,yEAAyE;YACzE,sEAAsE;YACtE,yEAAyE;YACzE,yEAAyE;YACzE,mCAAmC;YACnC,0BAA0B,EAAE,EAAE,KAAK,EAAE,wBAAwB,EAAE,UAAU,EAAE,QAAQ,EAAE;SACtF;KACF,CAAC,CAAA;IACF,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;QACzB,MAAM,CAAC,YAAY,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,MAAM,EAAE,CAAC,IAAa,EAAE,EAAE,CAAC,OAAO,CAAC,IAAI,EAAE,IAAI,EAAE,GAAG,CAAC,CAAC,CAAA;IAC1F,CAAC;IACD,4EAA4E;IAC5E,yEAAyE;IACzE,eAAe,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC5B,8EAA8E;IAC9E,8EAA8E;IAC9E,4DAA4D;IAC5D,iBAAiB,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC9B,OAAO,MAAM,CAAA;AACf,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@3ngram/server",
3
- "version": "1.4.3",
3
+ "version": "1.4.4",
4
4
  "description": "MCP server and REST API for persistent, typed AI-agent memory.",
5
5
  "license": "Apache-2.0",
6
6
  "homepage": "https://3ngram.ai",
@@ -63,9 +63,9 @@
63
63
  "rate-limiter-flexible": "11.2.0",
64
64
  "zod": "4.4.3",
65
65
  "@3ngram/config": "0.2.6",
66
- "@3ngram/core": "0.9.2",
67
66
  "@3ngram/llm": "0.2.4",
68
- "@3ngram/schema": "0.7.2"
67
+ "@3ngram/schema": "0.7.3",
68
+ "@3ngram/core": "0.9.3"
69
69
  },
70
70
  "devDependencies": {
71
71
  "@modelcontextprotocol/client": "2.0.0",