loopctl-mcp-server 2.37.0 → 2.38.0
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/README.md +2 -1
- package/index.js +37 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -121,7 +121,7 @@ REST endpoint (`PATCH /api/v1/tenants/me/llm-config`), and the docs — so you (
|
|
|
121
121
|
autonomous agent) can self-remediate without a human. Full agent-tenant lifecycle:
|
|
122
122
|
[`docs/onboarding-agent-tenant.md`](../docs/onboarding-agent-tenant.md).
|
|
123
123
|
|
|
124
|
-
## Tools (
|
|
124
|
+
## Tools (83)
|
|
125
125
|
|
|
126
126
|
### Project Tools
|
|
127
127
|
|
|
@@ -233,6 +233,7 @@ it is enforced server-side and a no-op for a non-superadmin key — see below.)
|
|
|
233
233
|
| `memory_recall` | Semantically recall your own long-term memories most similar to `query`. When embedding generation is unavailable the response degrades to a recent-first text match with `meta.fallback: true` and a stable `meta.reason` (score is `null` on that path) — check `meta.fallback` before treating a short/empty result as a genuinely empty scope. `meta.total_count`/`meta.underfilled` are also returned. Optional: `limit`, `include_superseded`. |
|
|
234
234
|
| `memory_list` | List your own long-term memories, newest first, paginated with `meta.total_count/limit/offset` (the true scoped count, never silently capped by `limit`). Optional: `limit`, `offset`, `include_superseded`, `all_subjects` (superadmin only; ignored for non-superadmin keys). |
|
|
235
235
|
| `memory_forget` | Delete one of your own long-term memories by id. A foreign-subject, foreign-tenant, or unknown id returns 404 (no existence leak). Required: `id`. |
|
|
236
|
+
| `memory_promote` | Call at session end to compile this session's short-term (`session`-tier) memory into durable `long_term` memory — unlike `memory_remember` (a single explicit write), this compiles the whole session in one shot; fire it once at session end, not per turn. Returns 202 with `{job_id, session_id, status: "enqueued"}` — promotion runs asynchronously, so the resulting memory is recallable via `memory_recall` only after the worker drains. You can only promote your own sessions (scope resolved server-side from your key). Required: `session_id`. |
|
|
236
237
|
|
|
237
238
|
### Knowledge Management Tools (orchestrator key)
|
|
238
239
|
|
package/index.js
CHANGED
|
@@ -1159,6 +1159,17 @@ async function memoryForget({ id }) {
|
|
|
1159
1159
|
return toContent(result);
|
|
1160
1160
|
}
|
|
1161
1161
|
|
|
1162
|
+
async function memoryPromote({ session_id }) {
|
|
1163
|
+
const payload = { session_id };
|
|
1164
|
+
const result = await apiCall(
|
|
1165
|
+
"POST",
|
|
1166
|
+
"/api/v1/memory/promote",
|
|
1167
|
+
payload,
|
|
1168
|
+
process.env.LOOPCTL_AGENT_KEY,
|
|
1169
|
+
);
|
|
1170
|
+
return toContent(result);
|
|
1171
|
+
}
|
|
1172
|
+
|
|
1162
1173
|
// --- Knowledge Management Tools (orch key) ---
|
|
1163
1174
|
|
|
1164
1175
|
async function knowledgePublish({ article_id }) {
|
|
@@ -3298,6 +3309,29 @@ const TOOLS = [
|
|
|
3298
3309
|
required: ["id"],
|
|
3299
3310
|
},
|
|
3300
3311
|
},
|
|
3312
|
+
{
|
|
3313
|
+
name: "memory_promote",
|
|
3314
|
+
description:
|
|
3315
|
+
"Call at session end to compile this session's short-term memory into durable long-term memory" +
|
|
3316
|
+
" — private, scoped working state, NOT the shared knowledge wiki. Unlike " +
|
|
3317
|
+
"memory_remember, which writes a single explicit fact, this compiles the WHOLE session's " +
|
|
3318
|
+
"session-tier memory in one shot — fire it once at session end, not per turn. Scope " +
|
|
3319
|
+
"(tenant_id/subject_id) is resolved server-side from your API key: you can only promote " +
|
|
3320
|
+
"your OWN sessions. Returns 202 Accepted with `{job_id, session_id, status: \"enqueued\"}` " +
|
|
3321
|
+
"— promotion runs asynchronously via a background worker, so the resulting long-term " +
|
|
3322
|
+
"memory becomes recallable via memory_recall only after that worker drains, not " +
|
|
3323
|
+
"immediately.",
|
|
3324
|
+
inputSchema: {
|
|
3325
|
+
type: "object",
|
|
3326
|
+
properties: {
|
|
3327
|
+
session_id: {
|
|
3328
|
+
type: "string",
|
|
3329
|
+
description: "The session whose short-term memory to compile into long-term memory.",
|
|
3330
|
+
},
|
|
3331
|
+
},
|
|
3332
|
+
required: ["session_id"],
|
|
3333
|
+
},
|
|
3334
|
+
},
|
|
3301
3335
|
|
|
3302
3336
|
// Knowledge Management Tools (orchestrator key)
|
|
3303
3337
|
{
|
|
@@ -4523,6 +4557,9 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
|
|
|
4523
4557
|
case "memory_forget":
|
|
4524
4558
|
return await memoryForget(args);
|
|
4525
4559
|
|
|
4560
|
+
case "memory_promote":
|
|
4561
|
+
return await memoryPromote(args);
|
|
4562
|
+
|
|
4526
4563
|
// Knowledge Management Tools
|
|
4527
4564
|
case "knowledge_publish":
|
|
4528
4565
|
return await knowledgePublish(args);
|