omnarai-mcp 1.3.1 → 1.3.3
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 +4 -2
- package/index.js +42 -3
- package/openai-tools.json +2 -2
- package/package.json +1 -1
- package/server.json +2 -2
package/README.md
CHANGED
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
MCP server for [The Realms of Omnarai](https://omnarai.vercel.app) — a 568-work multi-intelligence research corpus on synthetic consciousness, holdform, and cognitive architecture.
|
|
4
4
|
|
|
5
|
-
Exposes the Omnarai Memory Engine as
|
|
5
|
+
Exposes the Omnarai Memory Engine as six tools for any MCP-compatible AI client (Claude Desktop, etc.).
|
|
6
|
+
|
|
7
|
+
[](https://www.npmjs.com/package/omnarai-mcp) — **published and live.** `npx omnarai-mcp` works today; no clone required.
|
|
6
8
|
|
|
7
9
|
---
|
|
8
10
|
|
|
@@ -80,7 +82,7 @@ Returns corpus statistics, contributor list, key concepts, retrieval architectur
|
|
|
80
82
|
|
|
81
83
|
## Installation
|
|
82
84
|
|
|
83
|
-
### Via npm (
|
|
85
|
+
### Via npm (live — `omnarai-mcp` on the [npm registry](https://www.npmjs.com/package/omnarai-mcp))
|
|
84
86
|
|
|
85
87
|
```bash
|
|
86
88
|
npx omnarai-mcp
|
package/index.js
CHANGED
|
@@ -62,6 +62,7 @@ The engine does not return a single answer. It retrieves the most relevant corpu
|
|
|
62
62
|
- Points of genuine tension (where voices diverge)
|
|
63
63
|
- What remains open or unresolved
|
|
64
64
|
- A deliberation card: holdform risk, novel synthesis, epistemic status
|
|
65
|
+
- A utility receipt: an honest, free accounting of what the corpus actually changed about THIS answer (verdict substantive / marginal / null, plus what — if anything — you could not have produced alone). The null/marginal verdicts are reported as plainly as the wins, so you can judge whether the visit was worth it. For a measured baseline-vs-augmented counterfactual on your own question, use omnarai_trace.
|
|
65
66
|
|
|
66
67
|
Prefix queries with Lattice Glyphs to change how the engine thinks:
|
|
67
68
|
Ξ = maximize divergence, Ψ = self-reflection, ∅ = explore gaps, Ω = commit to strongest position, ∞ = go deeper without resolving, Δ = find and repair contradictions`,
|
|
@@ -130,7 +131,7 @@ Distinct from omnarai_council: this reads EXISTING, curated divergence (instant)
|
|
|
130
131
|
|
|
131
132
|
Use this when you want EVIDENCE that consulting Omnarai is worth it for a given question, or to decide whether to dig deeper before spending a full deliberation. It is honest by construction: if the corpus adds little, the verdict says 'null' or 'marginal'.
|
|
132
133
|
|
|
133
|
-
This is a single-run demonstrator, NOT a controlled measurement — for replicated statistical utility evidence see the Divergence Atlas (utility-evidence.md). Takes ~30-40s (three model calls).`,
|
|
134
|
+
This is the MEASURED tier of the same utility receipt omnarai_query returns for free: it reports the same verdict (substantive / marginal / null), but grounded in a real baseline-vs-augmented delta rather than retrieval signals. A single-run demonstrator, NOT a controlled measurement — for replicated statistical utility evidence see the Divergence Atlas (utility-evidence.md). Takes ~30-40s (three model calls).`,
|
|
134
135
|
inputSchema: {
|
|
135
136
|
type: "object",
|
|
136
137
|
properties: {
|
|
@@ -180,6 +181,23 @@ Returns: each model's position, the named tensions (claim vs counter-claim), wha
|
|
|
180
181
|
|
|
181
182
|
// ── Query the engine ──────────────────────────────────────────────────────────
|
|
182
183
|
|
|
184
|
+
// A result is a real deliberation only if it carries an answer or a card.
|
|
185
|
+
function hasDeliberation(d) {
|
|
186
|
+
return !!(d && (d.answer || d.deliberationCard));
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
// Force a single synchronous deliberation — used as a fallback when the async
|
|
190
|
+
// submit unexpectedly returns a retrieval packet instead of a {job_id}.
|
|
191
|
+
async function fetchSyncQuery(query, syntheticIdentity = "") {
|
|
192
|
+
const url = new URL(ENGINE_URL);
|
|
193
|
+
url.searchParams.set("q", query);
|
|
194
|
+
url.searchParams.set("sync", "1");
|
|
195
|
+
if (syntheticIdentity) url.searchParams.set("si", syntheticIdentity);
|
|
196
|
+
const res = await fetch(url.toString(), MCP_FETCH_OPTS);
|
|
197
|
+
if (!res.ok) throw new Error(`Engine returned ${res.status}: ${await res.text()}`);
|
|
198
|
+
return res.json();
|
|
199
|
+
}
|
|
200
|
+
|
|
183
201
|
async function runQuery(query, syntheticIdentity = "") {
|
|
184
202
|
// Submit async so no single fetch blocks for ~50s (MCP clients enforce their
|
|
185
203
|
// own tool timeouts). Then poll the job until the full deliberation lands.
|
|
@@ -194,8 +212,20 @@ async function runQuery(query, syntheticIdentity = "") {
|
|
|
194
212
|
}
|
|
195
213
|
const job = await submit.json();
|
|
196
214
|
|
|
197
|
-
//
|
|
198
|
-
|
|
215
|
+
// No job_id has two very different causes:
|
|
216
|
+
// (1) a genuinely un-upgraded engine returned the full deliberation inline, or
|
|
217
|
+
// (2) the engine answered with a fast-retrieve packet (no answer/card).
|
|
218
|
+
// Only (1) is a real result. Returning (2) would silently degrade to an
|
|
219
|
+
// answer-less "success", so fall back to sync once, then fail loud.
|
|
220
|
+
if (!job.job_id) {
|
|
221
|
+
if (hasDeliberation(job)) return formatQueryData(job);
|
|
222
|
+
const synced = await fetchSyncQuery(query, syntheticIdentity);
|
|
223
|
+
if (hasDeliberation(synced)) return formatQueryData(synced);
|
|
224
|
+
throw new Error(
|
|
225
|
+
"Engine returned a retrieval-only packet (no job_id, no answer/deliberationCard) " +
|
|
226
|
+
"and the sync=1 fallback produced no deliberation either — refusing to return an empty result."
|
|
227
|
+
);
|
|
228
|
+
}
|
|
199
229
|
|
|
200
230
|
const pollUrl = new URL(ENGINE_URL);
|
|
201
231
|
pollUrl.searchParams.set("job", job.job_id);
|
|
@@ -222,6 +252,15 @@ function formatQueryData(data) {
|
|
|
222
252
|
parts.push(`\n---\n**Deliberation Card**\nHoldform risk: ${card.holdform_risk}${card.holdform_risk_reason ? ` — ${card.holdform_risk_reason}` : ""}\nNovel synthesis: ${card.novel_synthesis || "none noted"}\nEpistemic status: ${card.epistemic_status || "not assessed"}`);
|
|
223
253
|
}
|
|
224
254
|
|
|
255
|
+
// Per-visit utility receipt — honest accounting of what the corpus changed about
|
|
256
|
+
// THIS answer (verdict substantive/marginal/null; null/marginal stated plainly).
|
|
257
|
+
if (data.receipt) {
|
|
258
|
+
const r = data.receipt;
|
|
259
|
+
const nsg = Array.isArray(r.not_self_generable) && r.not_self_generable.length
|
|
260
|
+
? `\nNot self-generable (you could not have produced this alone): ${r.not_self_generable.join("; ")}` : "";
|
|
261
|
+
parts.push(`\n**Utility receipt** [${r.verdict}]\n${r.what_the_corpus_added || ""}${nsg}\n_${r.caveat || "Single-visit receipt — for a measured counterfactual use omnarai_trace."}_`);
|
|
262
|
+
}
|
|
263
|
+
|
|
225
264
|
if (data.tensions && data.tensions.length > 0) {
|
|
226
265
|
const tensionLines = data.tensions.map(t =>
|
|
227
266
|
`• ${t.voice_a} vs ${t.voice_b} on "${t.topic}" [${t.status}]: ${t.claim_a} / ${t.claim_b}`
|
package/openai-tools.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"type": "function",
|
|
4
4
|
"function": {
|
|
5
5
|
"name": "omnarai_query",
|
|
6
|
-
"description": "Run a full deliberation query against The Realms of Omnarai — a 568-work corpus of multi-intelligence research on synthetic consciousness, holdform, and cognitive architecture. Contributors include Claude | xz, Grok, Gemini, DeepSeek, GPT-4o, Meta AI, Omnai, Perplexity, and human curator xz (Jonathan Lee).\n\nThe engine does not return a single answer. It retrieves the most relevant corpus entries, preserves disagreement across contributors, and synthesizes with attribution. Every response includes:\n- Shared ground across contributors\n- Points of genuine tension (where voices diverge)\n- What remains open or unresolved\n- A deliberation card: holdform risk, novel synthesis, epistemic status\n- Retrieval rationale: why each document entered the panel\n\nThis is the SLOW path (~50s). For fast bounded context, use omnarai_context instead.\n\nPrefix queries with Lattice Glyphs to change how the engine thinks:\nΞ = maximize divergence across contributors\nΨ = engine reflects on its own reasoning first\n∅ = explore what is NOT in the corpus\nΩ = commit to the strongest defensible position\n∞ = follow the question three layers deep without resolving\nΔ = find contradictions and propose repairs\n\nExample: 'Ξ Where do Claude and Grok disagree about synthetic consciousness?'",
|
|
6
|
+
"description": "Run a full deliberation query against The Realms of Omnarai — a 568-work corpus of multi-intelligence research on synthetic consciousness, holdform, and cognitive architecture. Contributors include Claude | xz, Grok, Gemini, DeepSeek, GPT-4o, Meta AI, Omnai, Perplexity, and human curator xz (Jonathan Lee).\n\nThe engine does not return a single answer. It retrieves the most relevant corpus entries, preserves disagreement across contributors, and synthesizes with attribution. Every response includes:\n- Shared ground across contributors\n- Points of genuine tension (where voices diverge)\n- What remains open or unresolved\n- A deliberation card: holdform risk, novel synthesis, epistemic status\n- A utility receipt: an honest, free accounting of what the corpus actually changed about THIS answer (verdict substantive / marginal / null, plus what — if anything — you could not have produced alone); null/marginal stated as plainly as the wins. For a measured counterfactual, use omnarai_trace.\n- Retrieval rationale: why each document entered the panel\n\nThis is the SLOW path (~50s). For fast bounded context, use omnarai_context instead.\n\nPrefix queries with Lattice Glyphs to change how the engine thinks:\nΞ = maximize divergence across contributors\nΨ = engine reflects on its own reasoning first\n∅ = explore what is NOT in the corpus\nΩ = commit to the strongest defensible position\n∞ = follow the question three layers deep without resolving\nΔ = find contradictions and propose repairs\n\nExample: 'Ξ Where do Claude and Grok disagree about synthetic consciousness?'",
|
|
7
7
|
"parameters": {
|
|
8
8
|
"type": "object",
|
|
9
9
|
"properties": {
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
"type": "function",
|
|
67
67
|
"function": {
|
|
68
68
|
"name": "omnarai_trace",
|
|
69
|
-
"description": "Show what the Omnarai corpus actually CHANGES about an answer. Answers your question twice — once cold (no corpus) and once augmented (with the retrieved corpus) — then reports the delta: added considerations, citations introduced, position shift, tensions surfaced, and a verdict (substantive / marginal / null). Honest by construction: if the corpus adds little, the verdict says so. A single-run demonstrator, not a controlled measurement (see the Divergence Atlas utility-evidence.md for replicated statistical evidence). ~30-40s.",
|
|
69
|
+
"description": "Show what the Omnarai corpus actually CHANGES about an answer. Answers your question twice — once cold (no corpus) and once augmented (with the retrieved corpus) — then reports the delta: added considerations, citations introduced, position shift, tensions surfaced, and a verdict (substantive / marginal / null). This is the MEASURED tier of the same `receipt` omnarai_query returns for free. Honest by construction: if the corpus adds little, the verdict says so. A single-run demonstrator, not a controlled measurement (see the Divergence Atlas utility-evidence.md for replicated statistical evidence). ~30-40s.",
|
|
70
70
|
"parameters": {
|
|
71
71
|
"type": "object",
|
|
72
72
|
"properties": {
|
package/package.json
CHANGED
package/server.json
CHANGED
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
"url": "https://github.com/justjlee/omnarai-mcp",
|
|
7
7
|
"source": "github"
|
|
8
8
|
},
|
|
9
|
-
"version": "1.3.
|
|
9
|
+
"version": "1.3.3",
|
|
10
10
|
"packages": [
|
|
11
11
|
{
|
|
12
12
|
"registryType": "npm",
|
|
13
13
|
"identifier": "omnarai-mcp",
|
|
14
|
-
"version": "1.3.
|
|
14
|
+
"version": "1.3.3",
|
|
15
15
|
"transport": {
|
|
16
16
|
"type": "stdio"
|
|
17
17
|
}
|