@theronap/agnoclast-mcp 0.9.229 → 0.9.230
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/lib/server.mjs +7 -4
- package/package.json +1 -1
package/lib/server.mjs
CHANGED
|
@@ -5177,19 +5177,22 @@ function renderNudge(payload) {
|
|
|
5177
5177
|
description: 'Set the CURRENCY of one of YOUR OWN authored pages so the brain can filter out stale info: "current" (reflects reality now — the default), "superseded" (replaced by a newer page — pass superseded_by with that page\'s name), or "historical" (kept for the record, no longer current). Optionally set modality: "reality" (as-built), "plan" (intended, not yet real), or "construction" (being built now). Call this the moment your understanding changes that a page is no longer the live truth — e.g. right after you author the new reality, mark the old page superseded. Owner-only.',
|
|
5178
5178
|
inputSchema: {
|
|
5179
5179
|
kind: z.enum(['project', 'person', 'org', 'user']).describe('the page kind'),
|
|
5180
|
-
name: z.string().describe('the exact page name'),
|
|
5180
|
+
name: z.string().optional().describe('the exact page name (or pass `ref` instead — one of the two is required)'),
|
|
5181
|
+
ref: z.string().optional().describe('the page\'s stable id, printed as `ref:` by read_page. PREFER THIS over name when you have it: a ref is unique across brains, so it never hits ambiguous_page_name.'),
|
|
5182
|
+
brain: z.string().optional().describe('optional: which brain the named page lives in, when the same name exists in several'),
|
|
5181
5183
|
validity: z.enum(['current', 'superseded', 'historical']).describe('the currency state'),
|
|
5182
5184
|
modality: z.enum(['reality', 'plan', 'construction']).optional().describe('what the page describes (optional)'),
|
|
5183
5185
|
superseded_by: z.string().optional().describe('for superseded: the name of the page that replaced it'),
|
|
5184
5186
|
},
|
|
5185
5187
|
},
|
|
5186
|
-
async ({ kind, name, validity, modality, superseded_by }) => {
|
|
5188
|
+
async ({ kind, name, ref, brain, validity, modality, superseded_by }) => {
|
|
5189
|
+
if (!name && !ref) return toolError('Could not set validity: pass `name` or `ref` (read_page prints the ref).')
|
|
5187
5190
|
let res
|
|
5188
5191
|
try {
|
|
5189
5192
|
res = await fetchCortex(`${BASE}/api/brain/validity`, {
|
|
5190
5193
|
method: 'POST',
|
|
5191
5194
|
headers: { Authorization: `Bearer ${TOKEN}`, 'Content-Type': 'application/json' },
|
|
5192
|
-
body: JSON.stringify({ kind, name, validity, modality, superseded_by }),
|
|
5195
|
+
body: JSON.stringify({ kind, name, ref, brain, validity, modality, superseded_by }),
|
|
5193
5196
|
})
|
|
5194
5197
|
} catch (e) {
|
|
5195
5198
|
return toolError(`Could not set validity: ${e.message}`)
|
|
@@ -5199,7 +5202,7 @@ function renderNudge(payload) {
|
|
|
5199
5202
|
return toolError(`Could not set validity: ${d.message}`)
|
|
5200
5203
|
}
|
|
5201
5204
|
const out = await res.json()
|
|
5202
|
-
return { content: [{ type: 'text', text: `Done — "${out.name}" is now ${out.validity}${out.modality ? ` / ${out.modality}` : ''} (${out.docs_updated} tier-doc(s) updated).` }] }
|
|
5205
|
+
return { content: [{ type: 'text', text: `Done — "${out.name ?? out.ref}" (${out.brain ?? 'brain ?'}) is now ${out.validity}${out.modality ? ` / ${out.modality}` : ''} (${out.docs_updated} tier-doc(s) updated).` }] }
|
|
5203
5206
|
},
|
|
5204
5207
|
)
|
|
5205
5208
|
|
package/package.json
CHANGED