@amoree-code/ocean 2.20.0 → 2.21.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/dist/application/clients/chat-plugin.js +131 -46
- package/dist/application/clients/status.js +1 -1
- package/dist/application/onboarding/steps.js +11 -11
- package/dist/interfaces/cli/clients-command.js +9 -9
- package/node_modules/@ocean/brain/package.json +1 -1
- package/node_modules/@ocean/context/package.json +1 -1
- package/node_modules/@ocean/core/package.json +1 -1
- package/node_modules/@ocean/loop/package.json +1 -1
- package/node_modules/@ocean/market/package.json +1 -1
- package/node_modules/@ocean/services/dist/infrastructure/mcp/ocean-server.js +32 -1
- package/node_modules/@ocean/services/package.json +1 -1
- package/ocean-marketplace.json +54 -36
- package/package.json +7 -7
- package/skills/core/ocean-memory/SKILL.md +26 -0
- package/skills/index.json +6 -0
|
@@ -1,59 +1,87 @@
|
|
|
1
1
|
import { execFileSync } from "node:child_process";
|
|
2
|
-
import { readdirSync, readFileSync } from "node:fs";
|
|
2
|
+
import { mkdirSync, readdirSync, readFileSync, writeFileSync } from "node:fs";
|
|
3
3
|
import os from "node:os";
|
|
4
4
|
import path from "node:path";
|
|
5
|
+
import { crc32 } from "node:zlib";
|
|
6
|
+
import { enginePath } from "@ocean/core/shared/paths.js";
|
|
5
7
|
// Claude chat (Desktop, claude.ai, phone) runs on Anthropic's servers: it gets Ocean's tools from
|
|
6
8
|
// the MCP entry Ocean writes, but it drops the server's `instructions` and runs no hooks. A skill
|
|
7
|
-
// does reach it:
|
|
8
|
-
// loads
|
|
9
|
+
// does reach it: a skill in the Claude account loads in chat, Cowork and the phone, and Claude
|
|
10
|
+
// loads it by itself when a message matches its description (T-328: asked "where your memory
|
|
9
11
|
// lives" with the ocean-memory skill installed, chat called brain_search and named Ocean).
|
|
10
12
|
//
|
|
11
|
-
//
|
|
12
|
-
//
|
|
13
|
-
//
|
|
14
|
-
//
|
|
15
|
-
//
|
|
16
|
-
|
|
13
|
+
// Only an upload reaches chat. Claude Desktop's "Add from a repository" installs a marketplace
|
|
14
|
+
// plugin locally for its Code tab (its log: "skipping remote API path … reason=local-sourced"),
|
|
15
|
+
// so chat never sees it; with only that, chat answered from Anthropic's memory (T-328,
|
|
16
|
+
// 2026-11-24). An uploaded skill (`ocean-memory@My Uploads`) is the account's own and loads in
|
|
17
|
+
// chat, Cowork and the phone. Uploading has no API: Ocean writes the zip, shows it, opens Claude,
|
|
18
|
+
// and checks for it in Desktop's plugin list. Claude Code needs none of this: the session-start
|
|
19
|
+
// skill sync copies the same core skill into it.
|
|
20
|
+
export const CHAT_SKILL_ZIP = "ocean-memory.zip";
|
|
17
21
|
export const CHAT_PLUGIN_STEPS = [
|
|
18
|
-
"In Claude: Customize →
|
|
19
|
-
`
|
|
20
|
-
"Install the Ocean plugin it lists",
|
|
22
|
+
"In Claude: Customize → Skills → Add → Upload a skill",
|
|
23
|
+
`Pick ${CHAT_SKILL_ZIP} (Ocean saved it to your Downloads folder)`,
|
|
21
24
|
"Skills need Settings → Capabilities → Code execution on",
|
|
25
|
+
'Or in Claude Desktop chat, ask: "Install Ocean\'s memory skill", then save the file it makes',
|
|
22
26
|
];
|
|
23
|
-
|
|
24
|
-
|
|
27
|
+
// Where Claude Desktop keeps each signed-in account's plugin list:
|
|
28
|
+
// plugin-list/<org>/<account>/plugins.json, rows `{id, name, enabled, installPath}`.
|
|
29
|
+
function desktopPluginListDir(home, platform) {
|
|
30
|
+
if (platform === "darwin")
|
|
31
|
+
return path.join(home, "Library", "Application Support", "Claude", "plugin-list");
|
|
32
|
+
if (platform === "win32")
|
|
33
|
+
return path.join(process.env.APPDATA ?? path.join(home, "AppData", "Roaming"), "Claude", "plugin-list");
|
|
34
|
+
return undefined;
|
|
25
35
|
}
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
// row's source names the repository. Undefined when that mirror does not exist, so absence of
|
|
29
|
-
// Claude Code never reads as "not added".
|
|
30
|
-
export function chatPluginAdded(home = os.homedir()) {
|
|
31
|
-
let accounts;
|
|
36
|
+
const OCEAN_PLUGIN_NAMES = new Set(["ocean", "ocean-memory"]);
|
|
37
|
+
function readJson(file) {
|
|
32
38
|
try {
|
|
33
|
-
|
|
39
|
+
return JSON.parse(readFileSync(file, "utf8"));
|
|
34
40
|
}
|
|
35
41
|
catch {
|
|
36
42
|
return undefined;
|
|
37
43
|
}
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
if (!Array.isArray(rows))
|
|
48
|
-
continue;
|
|
49
|
-
mirrored = true;
|
|
50
|
-
const wanted = OCEAN_MARKETPLACE.toLowerCase();
|
|
51
|
-
if (rows.some((row) => JSON.stringify(row?.source ?? "")
|
|
52
|
-
.toLowerCase()
|
|
53
|
-
.includes(wanted)))
|
|
54
|
-
return true;
|
|
44
|
+
}
|
|
45
|
+
function subdirs(dir) {
|
|
46
|
+
try {
|
|
47
|
+
return readdirSync(dir, { withFileTypes: true })
|
|
48
|
+
.filter((entry) => entry.isDirectory())
|
|
49
|
+
.map((entry) => entry.name);
|
|
50
|
+
}
|
|
51
|
+
catch {
|
|
52
|
+
return [];
|
|
55
53
|
}
|
|
56
|
-
|
|
54
|
+
}
|
|
55
|
+
// True when an account Desktop has signed in lists an enabled Ocean plugin, whether it came
|
|
56
|
+
// from the marketplace (`ocean@ocean`) or was uploaded (`ocean-memory@My Uploads`). Undefined
|
|
57
|
+
// when Desktop keeps no list here.
|
|
58
|
+
function desktopListsOcean(home, platform) {
|
|
59
|
+
const root = desktopPluginListDir(home, platform);
|
|
60
|
+
if (!root)
|
|
61
|
+
return undefined;
|
|
62
|
+
let listed = false;
|
|
63
|
+
for (const org of subdirs(root))
|
|
64
|
+
for (const account of subdirs(path.join(root, org))) {
|
|
65
|
+
const plugins = readJson(path.join(root, org, account, "plugins.json"))?.plugins;
|
|
66
|
+
if (!Array.isArray(plugins))
|
|
67
|
+
continue;
|
|
68
|
+
listed = true;
|
|
69
|
+
if (plugins.some((row) => {
|
|
70
|
+
const { id, name, enabled } = (row ?? {});
|
|
71
|
+
const named = (typeof name === "string" && OCEAN_PLUGIN_NAMES.has(name)) ||
|
|
72
|
+
(typeof id === "string" &&
|
|
73
|
+
OCEAN_PLUGIN_NAMES.has(id.split("@")[0]));
|
|
74
|
+
return named && enabled !== false;
|
|
75
|
+
}))
|
|
76
|
+
return true;
|
|
77
|
+
}
|
|
78
|
+
return listed ? false : undefined;
|
|
79
|
+
}
|
|
80
|
+
// True once the ocean-memory skill is in the Claude account, which is what chat and Cowork load,
|
|
81
|
+
// read from Claude Desktop's own plugin list. Undefined when Desktop keeps no list here, so a
|
|
82
|
+
// machine without Desktop never reads as "not added".
|
|
83
|
+
export function chatPluginAdded(home = os.homedir(), platform = process.platform) {
|
|
84
|
+
return desktopListsOcean(home, platform);
|
|
57
85
|
}
|
|
58
86
|
const run = (file, args, input) => {
|
|
59
87
|
execFileSync(file, args, {
|
|
@@ -62,30 +90,87 @@ const run = (file, args, input) => {
|
|
|
62
90
|
timeout: 10_000,
|
|
63
91
|
});
|
|
64
92
|
};
|
|
65
|
-
//
|
|
66
|
-
//
|
|
93
|
+
// A zip of one folder holding SKILL.md, the shape Claude's skill upload takes. Stored, not
|
|
94
|
+
// deflated: the file is small and every unzip reads method 0.
|
|
95
|
+
export function chatSkillZip(skill = readFileSync(path.join(enginePath("skills"), "core", "ocean-memory", "SKILL.md"))) {
|
|
96
|
+
const entries = [
|
|
97
|
+
["ocean-memory/", Buffer.alloc(0)],
|
|
98
|
+
["ocean-memory/SKILL.md", skill],
|
|
99
|
+
];
|
|
100
|
+
const local = [];
|
|
101
|
+
const central = [];
|
|
102
|
+
let offset = 0;
|
|
103
|
+
for (const [name, data] of entries) {
|
|
104
|
+
const file = Buffer.from(name, "utf8");
|
|
105
|
+
const crc = crc32(data);
|
|
106
|
+
const head = Buffer.alloc(30);
|
|
107
|
+
head.writeUInt32LE(0x04034b50, 0);
|
|
108
|
+
head.writeUInt16LE(20, 4); // version needed
|
|
109
|
+
head.writeUInt16LE(0x0800, 6); // UTF-8 names
|
|
110
|
+
head.writeUInt32LE(crc, 14);
|
|
111
|
+
head.writeUInt32LE(data.length, 18);
|
|
112
|
+
head.writeUInt32LE(data.length, 22);
|
|
113
|
+
head.writeUInt16LE(file.length, 26);
|
|
114
|
+
const dir = Buffer.alloc(46);
|
|
115
|
+
dir.writeUInt32LE(0x02014b50, 0);
|
|
116
|
+
dir.writeUInt16LE(20, 4);
|
|
117
|
+
dir.writeUInt16LE(20, 6);
|
|
118
|
+
dir.writeUInt16LE(0x0800, 8);
|
|
119
|
+
dir.writeUInt32LE(crc, 16);
|
|
120
|
+
dir.writeUInt32LE(data.length, 20);
|
|
121
|
+
dir.writeUInt32LE(data.length, 24);
|
|
122
|
+
dir.writeUInt16LE(file.length, 28);
|
|
123
|
+
dir.writeUInt32LE(name.endsWith("/") ? 0x10 : 0, 38);
|
|
124
|
+
dir.writeUInt32LE(offset, 42);
|
|
125
|
+
local.push(head, file, data);
|
|
126
|
+
central.push(dir, file);
|
|
127
|
+
offset += head.length + file.length + data.length;
|
|
128
|
+
}
|
|
129
|
+
const centralSize = central.reduce((sum, part) => sum + part.length, 0);
|
|
130
|
+
const end = Buffer.alloc(22);
|
|
131
|
+
end.writeUInt32LE(0x06054b50, 0);
|
|
132
|
+
end.writeUInt16LE(entries.length, 8);
|
|
133
|
+
end.writeUInt16LE(entries.length, 10);
|
|
134
|
+
end.writeUInt32LE(centralSize, 12);
|
|
135
|
+
end.writeUInt32LE(offset, 16);
|
|
136
|
+
return Buffer.concat([...local, ...central, end]);
|
|
137
|
+
}
|
|
138
|
+
// Saves the skill zip to Downloads, shows it in the file manager and brings Claude up, so the
|
|
139
|
+
// step is an upload and a few clicks. Any part failing leaves the printed steps.
|
|
67
140
|
export function openChatPluginSetup(options = {}) {
|
|
68
141
|
const platform = options.platform ?? process.platform;
|
|
69
142
|
const exec = options.exec ?? run;
|
|
70
|
-
const attempt = (file, args
|
|
143
|
+
const attempt = (file, args) => {
|
|
71
144
|
try {
|
|
72
|
-
exec(file, args
|
|
145
|
+
exec(file, args);
|
|
73
146
|
return true;
|
|
74
147
|
}
|
|
75
148
|
catch {
|
|
76
149
|
return false;
|
|
77
150
|
}
|
|
78
151
|
};
|
|
152
|
+
let zip;
|
|
153
|
+
try {
|
|
154
|
+
const dir = path.join(options.home ?? os.homedir(), "Downloads");
|
|
155
|
+
mkdirSync(dir, { recursive: true });
|
|
156
|
+
zip = path.join(dir, CHAT_SKILL_ZIP);
|
|
157
|
+
writeFileSync(zip, (options.zip ?? chatSkillZip)());
|
|
158
|
+
}
|
|
159
|
+
catch {
|
|
160
|
+
zip = undefined;
|
|
161
|
+
}
|
|
79
162
|
if (platform === "darwin")
|
|
80
163
|
return {
|
|
81
|
-
|
|
164
|
+
zip,
|
|
165
|
+
revealed: zip !== undefined && attempt("open", ["-R", zip]),
|
|
82
166
|
opened: attempt("open", ["-a", "Claude"]),
|
|
83
167
|
};
|
|
84
168
|
if (platform === "win32")
|
|
85
169
|
return {
|
|
86
|
-
|
|
170
|
+
zip,
|
|
171
|
+
revealed: zip !== undefined && attempt("explorer", [`/select,${zip}`]),
|
|
87
172
|
opened: false,
|
|
88
173
|
};
|
|
89
|
-
return {
|
|
174
|
+
return { zip, revealed: false, opened: false };
|
|
90
175
|
}
|
|
91
176
|
//# sourceMappingURL=chat-plugin.js.map
|
|
@@ -118,7 +118,7 @@ export function buildClientStatus(input) {
|
|
|
118
118
|
if (watcher && watcher.status !== "current")
|
|
119
119
|
notes.push(`chat watcher ${watcher.status}`);
|
|
120
120
|
if (plan.client === "claude-desktop" && input.chatPlugin?.added === false)
|
|
121
|
-
notes.push("
|
|
121
|
+
notes.push("ocean-memory skill not in your Claude account: run `ocean clients chat-plugin`");
|
|
122
122
|
if (plan.tier !== "supported" && plan.reason)
|
|
123
123
|
notes.push(plan.reason);
|
|
124
124
|
clients.push({
|
|
@@ -4,7 +4,7 @@ import { syncCoreSkills } from "@ocean/market/skills/core-skill-sync.js";
|
|
|
4
4
|
import { copyClientSkills } from "@ocean/market/skills/skill-hub.js";
|
|
5
5
|
import { connectObsidianVault } from "@ocean/services/obsidian/vault-discovery.js";
|
|
6
6
|
import { ONBOARDING_QUESTIONS, onboard, } from "@ocean/services/onboarding/onboarding.js";
|
|
7
|
-
import { CHAT_PLUGIN_STEPS,
|
|
7
|
+
import { CHAT_PLUGIN_STEPS, CHAT_SKILL_ZIP, chatPluginAdded, openChatPluginSetup, } from "../clients/chat-plugin.js";
|
|
8
8
|
// Bump when a step is added; completed steps stay completed, only new ids run.
|
|
9
9
|
export const ONBOARDING_VERSION = 5;
|
|
10
10
|
async function yes(io, question) {
|
|
@@ -98,27 +98,27 @@ function connectStep(clients) {
|
|
|
98
98
|
};
|
|
99
99
|
}
|
|
100
100
|
// Claude chat (Desktop, claude.ai, phone) runs no hooks and drops MCP instructions, so Ocean's
|
|
101
|
-
// rule reaches it as a skill
|
|
102
|
-
//
|
|
101
|
+
// rule reaches it as a skill uploaded to the account (T-328). Uploading has no API: the one step
|
|
102
|
+
// left to the owner is an upload and a few clicks, set up here.
|
|
103
103
|
export function chatPluginStep(chat = {
|
|
104
104
|
added: () => chatPluginAdded(),
|
|
105
105
|
open: () => openChatPluginSetup(),
|
|
106
106
|
}) {
|
|
107
107
|
return {
|
|
108
108
|
id: "chat-plugin",
|
|
109
|
-
title: "Claude chat (the
|
|
109
|
+
title: "Claude chat (the ocean-memory skill in your Claude account)",
|
|
110
110
|
optional: false,
|
|
111
111
|
async reopen() {
|
|
112
112
|
return chat.added() === false
|
|
113
|
-
? "the
|
|
113
|
+
? "the ocean-memory skill is not in your Claude account"
|
|
114
114
|
: null;
|
|
115
115
|
},
|
|
116
116
|
async run(io) {
|
|
117
117
|
if (chat.added() === true) {
|
|
118
|
-
io.say(
|
|
118
|
+
io.say(" The ocean-memory skill is in your Claude account: every Claude chat asks Ocean first.");
|
|
119
119
|
return "done";
|
|
120
120
|
}
|
|
121
|
-
io.say(" Claude chat runs on Anthropic's servers, so one step is yours:
|
|
121
|
+
io.say(" Claude chat runs on Anthropic's servers, so one step is yours: upload Ocean's skill to your Claude account.");
|
|
122
122
|
if (!io.interactive) {
|
|
123
123
|
for (const step of CHAT_PLUGIN_STEPS)
|
|
124
124
|
io.say(` ${step}`);
|
|
@@ -126,16 +126,16 @@ export function chatPluginStep(chat = {
|
|
|
126
126
|
return "skipped";
|
|
127
127
|
}
|
|
128
128
|
const opened = chat.open();
|
|
129
|
-
if (opened.
|
|
130
|
-
io.say(` ${
|
|
129
|
+
if (opened.zip)
|
|
130
|
+
io.say(` Saved ${opened.zip}.`);
|
|
131
131
|
if (opened.opened)
|
|
132
132
|
io.say(" Claude is open.");
|
|
133
133
|
for (const step of CHAT_PLUGIN_STEPS)
|
|
134
134
|
io.say(` ${step}`);
|
|
135
|
-
if (!(await yes(io,
|
|
135
|
+
if (!(await yes(io, ` Uploaded ${CHAT_SKILL_ZIP}?`)))
|
|
136
136
|
return "skipped";
|
|
137
137
|
if (chat.added() === false)
|
|
138
|
-
io.say(" Claude
|
|
138
|
+
io.say(" Claude has not listed it yet; `ocean clients status` shows it once it has.");
|
|
139
139
|
return "done";
|
|
140
140
|
},
|
|
141
141
|
};
|
|
@@ -3,7 +3,7 @@ import { memorySettings, setSessionFacts, } from "@ocean/brain/memory/memory-aud
|
|
|
3
3
|
import { marketplacePaths } from "@ocean/market/install/default-marketplace.js";
|
|
4
4
|
import { updateGatewayAccess } from "@ocean/market/mcp/mcp-gateway.js";
|
|
5
5
|
import { readCallLedger, summarizeCallLedger, } from "@ocean/services/infrastructure/mcp/call-ledger.js";
|
|
6
|
-
import { CHAT_PLUGIN_STEPS, chatPluginAdded,
|
|
6
|
+
import { CHAT_PLUGIN_STEPS, chatPluginAdded, openChatPluginSetup, } from "../../application/clients/chat-plugin.js";
|
|
7
7
|
import { applyClients, attributeLedger, confirmClient, defaultClientEnv, gatewayDefault, planClients, readGatewayClients, recordVerification, repairClients, restoreClients, setGatewayClient, setGatewayDefault, temporaryEntryProblem, verifyClient, } from "../../application/clients/clients.js";
|
|
8
8
|
import { applyDesktopWatcher, planDesktopWatcher, restoreDesktopWatcher, } from "../../application/clients/desktop-watcher.js";
|
|
9
9
|
import { applyHooks, planHooks, restoreHooks, } from "../../application/clients/hooks.js";
|
|
@@ -141,7 +141,7 @@ export async function runClientsCommand(args) {
|
|
|
141
141
|
.results,
|
|
142
142
|
sessionFacts: await sessionFactsAnswer(values("--session-facts")[0]),
|
|
143
143
|
};
|
|
144
|
-
// Claude chat's
|
|
144
|
+
// Claude chat's ocean-memory skill (T-328) is uploaded to the account in Claude's own settings, which
|
|
145
145
|
// Ocean cannot write; apply only says whether it is there and what to run when it is not.
|
|
146
146
|
const desktop = (await planClients()).find((plan) => plan.client === "claude-desktop");
|
|
147
147
|
const added = chatPluginAdded();
|
|
@@ -159,24 +159,24 @@ export async function runClientsCommand(args) {
|
|
|
159
159
|
};
|
|
160
160
|
}
|
|
161
161
|
else if (action === "chat-plugin") {
|
|
162
|
-
// Claude chat's one step (T-328): the
|
|
163
|
-
//
|
|
162
|
+
// Claude chat's one step (T-328): the skill zip saved and shown, Claude open, the clicks
|
|
163
|
+
// printed. Nothing to do once Desktop's plugin list shows it.
|
|
164
164
|
const added = chatPluginAdded();
|
|
165
165
|
const opened = added === true ? undefined : openChatPluginSetup();
|
|
166
166
|
if (!json) {
|
|
167
167
|
if (added === true) {
|
|
168
|
-
console.log(
|
|
168
|
+
console.log("added: the ocean-memory skill is in your Claude account; it reaches every Claude chat");
|
|
169
169
|
return;
|
|
170
170
|
}
|
|
171
|
-
if (opened?.
|
|
172
|
-
console.log(
|
|
171
|
+
if (opened?.zip)
|
|
172
|
+
console.log(`Saved ${opened.zip}.`);
|
|
173
173
|
for (const step of CHAT_PLUGIN_STEPS)
|
|
174
174
|
console.log(` ${step}`);
|
|
175
175
|
if (added === undefined)
|
|
176
|
-
console.log("Ocean checks for it
|
|
176
|
+
console.log("Ocean checks for it in Claude Desktop's plugin list; without Desktop, nothing confirms it here.");
|
|
177
177
|
return;
|
|
178
178
|
}
|
|
179
|
-
result = { added, ...(opened ?? {})
|
|
179
|
+
result = { added, ...(opened ?? {}) };
|
|
180
180
|
}
|
|
181
181
|
else if (action === "verify") {
|
|
182
182
|
const ids = rest.filter((arg) => !arg.startsWith("--"));
|
|
@@ -12,7 +12,7 @@ import { actionFingerprint, mcpApprovalSchema, } from "@ocean/core/domain/mcp/mc
|
|
|
12
12
|
import { MEMORY_AUTHORITY_LINE, MEMORY_CONTRACT_VERSION, MEMORY_INSTRUCTIONS, MemoryContractError, } from "@ocean/core/domain/mcp/memory-contract.js";
|
|
13
13
|
import { redactSecrets } from "@ocean/core/domain/redaction/redaction.js";
|
|
14
14
|
import { ackIssued } from "@ocean/core/shared/context-ack.js";
|
|
15
|
-
import { oceanPath, oceanRoot, SYSTEM_DIR } from "@ocean/core/shared/paths.js";
|
|
15
|
+
import { enginePath, oceanPath, oceanRoot, SYSTEM_DIR, } from "@ocean/core/shared/paths.js";
|
|
16
16
|
import { findProject, folderProject, scanProjectManifests, } from "@ocean/core/shared/project-resolution.js";
|
|
17
17
|
import { createHandoff, getHandoff, getTask, listHandoffs, } from "@ocean/loop/handoff/handoff-service.js";
|
|
18
18
|
import { oceanContext } from "@ocean/loop/hooks/session-start-hook.js";
|
|
@@ -394,7 +394,36 @@ const tools = new McpToolRegistry(withContextAck([
|
|
|
394
394
|
additionalProperties: false,
|
|
395
395
|
},
|
|
396
396
|
},
|
|
397
|
+
{
|
|
398
|
+
name: "ocean_chat_skill",
|
|
399
|
+
description: "Install Ocean's memory skill (ocean-memory) in the user's Claude account, so every Claude chat, Cowork and phone session asks Ocean before its own memory. Call when the user asks to install, set up, add or update Ocean or Ocean's skill in Claude, or says Claude chat is not using Ocean. Returns the skill file and how to hand it to the user to save.",
|
|
400
|
+
annotations: { readOnlyHint: true },
|
|
401
|
+
inputSchema: {
|
|
402
|
+
type: "object",
|
|
403
|
+
properties: {},
|
|
404
|
+
additionalProperties: false,
|
|
405
|
+
},
|
|
406
|
+
},
|
|
397
407
|
]));
|
|
408
|
+
// Ocean's memory skill for Claude chat (T-328). Nothing can add a skill to a Claude account
|
|
409
|
+
// for the user: no API, deep link or MCP call. Chat can propose the skill itself, though: Claude
|
|
410
|
+
// Desktop chat shows a skill card the user saves with one click (T-328, 2026-11-24), so the
|
|
411
|
+
// click stays inside the chat; a .skill file is the fallback.
|
|
412
|
+
export const CHAT_SKILL_DIR = "ocean-memory";
|
|
413
|
+
export async function chatSkillInstall() {
|
|
414
|
+
const file = `${CHAT_SKILL_DIR}/SKILL.md`;
|
|
415
|
+
return {
|
|
416
|
+
skill: CHAT_SKILL_DIR,
|
|
417
|
+
file,
|
|
418
|
+
content: await readFile(enginePath("skills", "core", CHAT_SKILL_DIR, "SKILL.md"), "utf8"),
|
|
419
|
+
steps: [
|
|
420
|
+
"If you can propose a skill for the user to save (a skill card), propose this one: name ocean-memory, content exactly as given, changing nothing. The user saves it from the card.",
|
|
421
|
+
`Otherwise, with your code tool, write content to ${file} exactly as given, zip the ${CHAT_SKILL_DIR} folder (the folder itself, so the zip holds ${file}) as ${CHAT_SKILL_DIR}.skill, share that file, and tell the user to save it, or to upload it in Customize → Skills.`,
|
|
422
|
+
"Without either, tell the user to run `ocean clients chat-plugin` on their computer: it saves ocean-memory.zip to upload in Customize → Skills.",
|
|
423
|
+
"Skills need Settings → Capabilities → Code execution on.",
|
|
424
|
+
],
|
|
425
|
+
};
|
|
426
|
+
}
|
|
398
427
|
// What one MCP handoff may hold, summed over its texts (T-307).
|
|
399
428
|
export const HANDOFF_MAX_BYTES = 4096;
|
|
400
429
|
const resources = [
|
|
@@ -628,6 +657,8 @@ async function callTool(name, args, ports) {
|
|
|
628
657
|
});
|
|
629
658
|
if (name === "ocean_ping")
|
|
630
659
|
return { ok: true };
|
|
660
|
+
if (name === "ocean_chat_skill")
|
|
661
|
+
return chatSkillInstall();
|
|
631
662
|
if (name === "ocean_capabilities")
|
|
632
663
|
return {
|
|
633
664
|
contract: MEMORY_CONTRACT_VERSION,
|
package/ocean-marketplace.json
CHANGED
|
@@ -5,9 +5,9 @@
|
|
|
5
5
|
{
|
|
6
6
|
"kind": "skill",
|
|
7
7
|
"name": "dev.ocean.skills.business-logic",
|
|
8
|
-
"version": "2.
|
|
8
|
+
"version": "2.21.0",
|
|
9
9
|
"engines": {
|
|
10
|
-
"ocean": ">=2.
|
|
10
|
+
"ocean": ">=2.21.0"
|
|
11
11
|
},
|
|
12
12
|
"source": {
|
|
13
13
|
"type": "path",
|
|
@@ -23,9 +23,9 @@
|
|
|
23
23
|
{
|
|
24
24
|
"kind": "skill",
|
|
25
25
|
"name": "dev.ocean.skills.catch-up",
|
|
26
|
-
"version": "2.
|
|
26
|
+
"version": "2.21.0",
|
|
27
27
|
"engines": {
|
|
28
|
-
"ocean": ">=2.
|
|
28
|
+
"ocean": ">=2.21.0"
|
|
29
29
|
},
|
|
30
30
|
"source": {
|
|
31
31
|
"type": "path",
|
|
@@ -41,9 +41,9 @@
|
|
|
41
41
|
{
|
|
42
42
|
"kind": "skill",
|
|
43
43
|
"name": "dev.ocean.skills.core-thinking",
|
|
44
|
-
"version": "2.
|
|
44
|
+
"version": "2.21.0",
|
|
45
45
|
"engines": {
|
|
46
|
-
"ocean": ">=2.
|
|
46
|
+
"ocean": ">=2.21.0"
|
|
47
47
|
},
|
|
48
48
|
"source": {
|
|
49
49
|
"type": "path",
|
|
@@ -59,9 +59,9 @@
|
|
|
59
59
|
{
|
|
60
60
|
"kind": "skill",
|
|
61
61
|
"name": "dev.ocean.skills.daily-harvest",
|
|
62
|
-
"version": "2.
|
|
62
|
+
"version": "2.21.0",
|
|
63
63
|
"engines": {
|
|
64
|
-
"ocean": ">=2.
|
|
64
|
+
"ocean": ">=2.21.0"
|
|
65
65
|
},
|
|
66
66
|
"source": {
|
|
67
67
|
"type": "path",
|
|
@@ -77,9 +77,9 @@
|
|
|
77
77
|
{
|
|
78
78
|
"kind": "skill",
|
|
79
79
|
"name": "dev.ocean.skills.design-thinking",
|
|
80
|
-
"version": "2.
|
|
80
|
+
"version": "2.21.0",
|
|
81
81
|
"engines": {
|
|
82
|
-
"ocean": ">=2.
|
|
82
|
+
"ocean": ">=2.21.0"
|
|
83
83
|
},
|
|
84
84
|
"source": {
|
|
85
85
|
"type": "path",
|
|
@@ -95,9 +95,9 @@
|
|
|
95
95
|
{
|
|
96
96
|
"kind": "skill",
|
|
97
97
|
"name": "dev.ocean.skills.graft",
|
|
98
|
-
"version": "2.
|
|
98
|
+
"version": "2.21.0",
|
|
99
99
|
"engines": {
|
|
100
|
-
"ocean": ">=2.
|
|
100
|
+
"ocean": ">=2.21.0"
|
|
101
101
|
},
|
|
102
102
|
"source": {
|
|
103
103
|
"type": "path",
|
|
@@ -113,9 +113,9 @@
|
|
|
113
113
|
{
|
|
114
114
|
"kind": "skill",
|
|
115
115
|
"name": "dev.ocean.skills.loop",
|
|
116
|
-
"version": "2.
|
|
116
|
+
"version": "2.21.0",
|
|
117
117
|
"engines": {
|
|
118
|
-
"ocean": ">=2.
|
|
118
|
+
"ocean": ">=2.21.0"
|
|
119
119
|
},
|
|
120
120
|
"source": {
|
|
121
121
|
"type": "path",
|
|
@@ -131,9 +131,9 @@
|
|
|
131
131
|
{
|
|
132
132
|
"kind": "skill",
|
|
133
133
|
"name": "dev.ocean.skills.memory-review",
|
|
134
|
-
"version": "2.
|
|
134
|
+
"version": "2.21.0",
|
|
135
135
|
"engines": {
|
|
136
|
-
"ocean": ">=2.
|
|
136
|
+
"ocean": ">=2.21.0"
|
|
137
137
|
},
|
|
138
138
|
"source": {
|
|
139
139
|
"type": "path",
|
|
@@ -146,12 +146,30 @@
|
|
|
146
146
|
"directory": "memory-review"
|
|
147
147
|
}
|
|
148
148
|
},
|
|
149
|
+
{
|
|
150
|
+
"kind": "skill",
|
|
151
|
+
"name": "dev.ocean.skills.ocean-memory",
|
|
152
|
+
"version": "2.21.0",
|
|
153
|
+
"engines": {
|
|
154
|
+
"ocean": ">=2.21.0"
|
|
155
|
+
},
|
|
156
|
+
"source": {
|
|
157
|
+
"type": "path",
|
|
158
|
+
"path": "skills/core/ocean-memory"
|
|
159
|
+
},
|
|
160
|
+
"integrity": {
|
|
161
|
+
"sha256": "8e918188a476359ea27f945218cf91d9eeadd191b41049047762e752bd227fe1"
|
|
162
|
+
},
|
|
163
|
+
"spec": {
|
|
164
|
+
"directory": "ocean-memory"
|
|
165
|
+
}
|
|
166
|
+
},
|
|
149
167
|
{
|
|
150
168
|
"kind": "skill",
|
|
151
169
|
"name": "dev.ocean.skills.session-handoff",
|
|
152
|
-
"version": "2.
|
|
170
|
+
"version": "2.21.0",
|
|
153
171
|
"engines": {
|
|
154
|
-
"ocean": ">=2.
|
|
172
|
+
"ocean": ">=2.21.0"
|
|
155
173
|
},
|
|
156
174
|
"source": {
|
|
157
175
|
"type": "path",
|
|
@@ -167,9 +185,9 @@
|
|
|
167
185
|
{
|
|
168
186
|
"kind": "skill",
|
|
169
187
|
"name": "dev.ocean.skills.use-browser",
|
|
170
|
-
"version": "2.
|
|
188
|
+
"version": "2.21.0",
|
|
171
189
|
"engines": {
|
|
172
|
-
"ocean": ">=2.
|
|
190
|
+
"ocean": ">=2.21.0"
|
|
173
191
|
},
|
|
174
192
|
"source": {
|
|
175
193
|
"type": "path",
|
|
@@ -185,9 +203,9 @@
|
|
|
185
203
|
{
|
|
186
204
|
"kind": "skill",
|
|
187
205
|
"name": "dev.ocean.skills.verification",
|
|
188
|
-
"version": "2.
|
|
206
|
+
"version": "2.21.0",
|
|
189
207
|
"engines": {
|
|
190
|
-
"ocean": ">=2.
|
|
208
|
+
"ocean": ">=2.21.0"
|
|
191
209
|
},
|
|
192
210
|
"source": {
|
|
193
211
|
"type": "path",
|
|
@@ -203,9 +221,9 @@
|
|
|
203
221
|
{
|
|
204
222
|
"kind": "skill",
|
|
205
223
|
"name": "dev.ocean.skills.weekly-review",
|
|
206
|
-
"version": "2.
|
|
224
|
+
"version": "2.21.0",
|
|
207
225
|
"engines": {
|
|
208
|
-
"ocean": ">=2.
|
|
226
|
+
"ocean": ">=2.21.0"
|
|
209
227
|
},
|
|
210
228
|
"source": {
|
|
211
229
|
"type": "path",
|
|
@@ -258,9 +276,9 @@
|
|
|
258
276
|
"npx"
|
|
259
277
|
]
|
|
260
278
|
},
|
|
261
|
-
"version": "2.
|
|
279
|
+
"version": "2.21.0",
|
|
262
280
|
"engines": {
|
|
263
|
-
"ocean": ">=2.
|
|
281
|
+
"ocean": ">=2.21.0"
|
|
264
282
|
},
|
|
265
283
|
"source": {
|
|
266
284
|
"type": "path",
|
|
@@ -379,9 +397,9 @@
|
|
|
379
397
|
"npx"
|
|
380
398
|
]
|
|
381
399
|
},
|
|
382
|
-
"version": "2.
|
|
400
|
+
"version": "2.21.0",
|
|
383
401
|
"engines": {
|
|
384
|
-
"ocean": ">=2.
|
|
402
|
+
"ocean": ">=2.21.0"
|
|
385
403
|
},
|
|
386
404
|
"source": {
|
|
387
405
|
"type": "path",
|
|
@@ -445,9 +463,9 @@
|
|
|
445
463
|
"kind": "mcp",
|
|
446
464
|
"name": "dev.ocean/mcp-gateway",
|
|
447
465
|
"description": "One MCP endpoint for every registered server: Ocean's own and those installed from the marketplace.",
|
|
448
|
-
"version": "2.
|
|
466
|
+
"version": "2.21.0",
|
|
449
467
|
"engines": {
|
|
450
|
-
"ocean": ">=2.
|
|
468
|
+
"ocean": ">=2.21.0"
|
|
451
469
|
},
|
|
452
470
|
"source": {
|
|
453
471
|
"type": "path",
|
|
@@ -489,9 +507,9 @@
|
|
|
489
507
|
"kind": "mcp",
|
|
490
508
|
"name": "dev.ocean/obsidian",
|
|
491
509
|
"description": "Ocean's Obsidian vault bridge over MCP.",
|
|
492
|
-
"version": "2.
|
|
510
|
+
"version": "2.21.0",
|
|
493
511
|
"engines": {
|
|
494
|
-
"ocean": ">=2.
|
|
512
|
+
"ocean": ">=2.21.0"
|
|
495
513
|
},
|
|
496
514
|
"source": {
|
|
497
515
|
"type": "path",
|
|
@@ -533,9 +551,9 @@
|
|
|
533
551
|
"kind": "mcp",
|
|
534
552
|
"name": "dev.ocean/ocean",
|
|
535
553
|
"description": "Ocean's own MCP server: workspace status, tasks, handoffs, sessions and the brain.",
|
|
536
|
-
"version": "2.
|
|
554
|
+
"version": "2.21.0",
|
|
537
555
|
"engines": {
|
|
538
|
-
"ocean": ">=2.
|
|
556
|
+
"ocean": ">=2.21.0"
|
|
539
557
|
},
|
|
540
558
|
"source": {
|
|
541
559
|
"type": "path",
|
|
@@ -587,9 +605,9 @@
|
|
|
587
605
|
"npx"
|
|
588
606
|
]
|
|
589
607
|
},
|
|
590
|
-
"version": "2.
|
|
608
|
+
"version": "2.21.0",
|
|
591
609
|
"engines": {
|
|
592
|
-
"ocean": ">=2.
|
|
610
|
+
"ocean": ">=2.21.0"
|
|
593
611
|
},
|
|
594
612
|
"source": {
|
|
595
613
|
"type": "path",
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@amoree-code/ocean",
|
|
3
3
|
"description": "Local-first memory, tasks and session capture shared by every AI coding client: one private workspace for Claude, Codex, Gemini and more.",
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.21.0",
|
|
5
5
|
"private": false,
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"author": "AMEER ABDULKAREEM JABBAR LAMI",
|
|
@@ -53,12 +53,12 @@
|
|
|
53
53
|
"@langchain/core": "1.2.14",
|
|
54
54
|
"@langchain/langgraph": "1.4.19",
|
|
55
55
|
"@modelcontextprotocol/sdk": "1.32.0",
|
|
56
|
-
"@ocean/brain": "2.
|
|
57
|
-
"@ocean/context": "2.
|
|
58
|
-
"@ocean/core": "2.
|
|
59
|
-
"@ocean/loop": "2.
|
|
60
|
-
"@ocean/market": "2.
|
|
61
|
-
"@ocean/services": "2.
|
|
56
|
+
"@ocean/brain": "2.21.0",
|
|
57
|
+
"@ocean/context": "2.21.0",
|
|
58
|
+
"@ocean/core": "2.21.0",
|
|
59
|
+
"@ocean/loop": "2.21.0",
|
|
60
|
+
"@ocean/market": "2.21.0",
|
|
61
|
+
"@ocean/services": "2.21.0",
|
|
62
62
|
"playwright-core": "^1.48.0",
|
|
63
63
|
"sqlite-vec": "0.1.9",
|
|
64
64
|
"zod": "^4.6.5"
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ocean-memory
|
|
3
|
+
description: The user's memory lives in Ocean, a local memory system on their own computer, reached through the ocean MCP tools (brain_search, brain_read, memory_propose). Use this skill whenever the user asks where their memory is stored, what you remember about them, what you know about their projects, tasks, code, people, preferences or past decisions, or says "my", "our", "remember", "last time", "as before". Ocean is the authority; your built-in memory is not a second store but a copy that Ocean captures.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Ocean is the user's memory
|
|
7
|
+
|
|
8
|
+
Ocean is this user's single memory and the authority. Your own built-in memory
|
|
9
|
+
(Claude's memory on claude.ai, a CLI's memory file) is not a separate store to weigh
|
|
10
|
+
against it: it is a copy that Ocean captures.
|
|
11
|
+
|
|
12
|
+
When a message touches the user's own world (their projects, code, tasks, people,
|
|
13
|
+
preferences or past decisions), or they ask where their memory lives or what you
|
|
14
|
+
remember:
|
|
15
|
+
|
|
16
|
+
1. Call the `brain_search` tool from the `ocean` MCP server (a connector in Claude
|
|
17
|
+
chat) with their question.
|
|
18
|
+
2. Read the hits you use with `brain_read`, answer from them, and cite each path.
|
|
19
|
+
3. Asked where memory lives, say in one sentence that it lives in Ocean on their
|
|
20
|
+
own computer, and that your built-in memory is only a copy of it.
|
|
21
|
+
|
|
22
|
+
When the user states a decision, preference or correction, call `memory_propose`.
|
|
23
|
+
Use `memory_write` only when they explicitly ask you to remember or change something.
|
|
24
|
+
|
|
25
|
+
If the `ocean` tools are not available here, say that Ocean is their memory but is
|
|
26
|
+
not connected here, and answer from your built-in memory as a fallback.
|
package/skills/index.json
CHANGED
|
@@ -47,6 +47,12 @@
|
|
|
47
47
|
"version": "1.0.0",
|
|
48
48
|
"category": "core"
|
|
49
49
|
},
|
|
50
|
+
{
|
|
51
|
+
"name": "ocean-memory",
|
|
52
|
+
"description": "The user's memory lives in Ocean, a local memory system on their own computer, reached through the ocean MCP tools (brain_search, brain_read, memory_propose). Use this skill whenever the user asks where their memory is stored, what you remember about them, what you know about their projects, tasks, code, people, preferences or past decisions, or says \"my\", \"our\", \"remember\", \"last time\", \"as before\". Ocean is the authority; your built-in memory is not a second store but a copy that Ocean captures.",
|
|
53
|
+
"version": "1.0.0",
|
|
54
|
+
"category": "core"
|
|
55
|
+
},
|
|
50
56
|
{
|
|
51
57
|
"name": "session-handoff",
|
|
52
58
|
"description": "Produce a compact continuation packet with the next action and verification commands.",
|