@amoree-code/ocean 2.21.0 โ 2.22.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/interfaces/cli/command-registry.js +3 -0
- package/node_modules/@ocean/brain/package.json +1 -1
- package/node_modules/@ocean/context/package.json +1 -1
- package/node_modules/@ocean/core/dist/shared/visibility.js +68 -0
- package/node_modules/@ocean/core/package.json +1 -1
- package/node_modules/@ocean/loop/dist/hooks/session-start-hook.js +7 -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 +7 -1
- package/node_modules/@ocean/services/package.json +1 -1
- package/ocean-marketplace.json +39 -39
- package/package.json +7 -7
- package/skills/core/ocean-memory/SKILL.md +5 -0
|
@@ -9,6 +9,7 @@ import { resolveProfileName } from "@ocean/core/domain/profiles/runtime-config.j
|
|
|
9
9
|
import { GUARD_FLAGS, parseGuardFlags, } from "@ocean/core/domain/runs/loop-guard.js";
|
|
10
10
|
import { oceanEnv, oceanPath, oceanRoot, SYSTEM_DIR, } from "@ocean/core/shared/paths.js";
|
|
11
11
|
import { autoRegisterProject, bindProject, createProject, findGitRoot, knownTaskPrefixes, listProjectBindings, migrateProjectBindings, moveProject, PROJECT_CATEGORIES, projectCategory, renameProject, renderProjectIndex, resolveProject, scanProjectManifests, unbindProjectPath, writeProjectIndex, } from "@ocean/core/shared/project-resolution.js";
|
|
12
|
+
import { recordSynced } from "@ocean/core/shared/visibility.js";
|
|
12
13
|
import { claudeSessionEndHook, isSessionEndClient, SESSION_END_CLIENTS, } from "@ocean/loop/hooks/session-end-hook.js";
|
|
13
14
|
import { isSessionStartClient, readBoundedStdin, SESSION_START_CLIENTS, sessionStartHookForClient, } from "@ocean/loop/hooks/session-start-hook.js";
|
|
14
15
|
import { openSessionStore } from "@ocean/loop/infrastructure/persistence/session-store.js";
|
|
@@ -207,6 +208,8 @@ async function commandClient() {
|
|
|
207
208
|
const clients = await repairClients().catch((error) => ({
|
|
208
209
|
error: error instanceof Error ? error.message : String(error),
|
|
209
210
|
}));
|
|
211
|
+
// T-328 phase 3: status lines show `synced <age>` from this stamp.
|
|
212
|
+
await recordSynced();
|
|
210
213
|
console.log(JSON.stringify({
|
|
211
214
|
directory: result.directory,
|
|
212
215
|
providers: result.providers,
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { mkdir, readFile, writeFile } from "node:fs/promises";
|
|
2
|
+
import path from "node:path";
|
|
3
|
+
import { withFileLock } from "./fs-utils.js";
|
|
4
|
+
import { oceanPath, SYSTEM_DIR } from "./paths.js";
|
|
5
|
+
// VISIBILITY (T-328 phase 3): the owner can see Ocean is on without asking. A start hook notes
|
|
6
|
+
// which Ocean project each folder resolved to, and `ocean client sync` notes when it last ran.
|
|
7
|
+
// Status lines read this one small file with jq instead of starting the CLI on every refresh.
|
|
8
|
+
// It holds folder paths, project ids and timestamps only โ never memory content.
|
|
9
|
+
export const VISIBILITY_MAX_FOLDERS = 50;
|
|
10
|
+
export function visibilityFile() {
|
|
11
|
+
return oceanPath(SYSTEM_DIR, "state", "visibility.json");
|
|
12
|
+
}
|
|
13
|
+
export function connectedLine(project) {
|
|
14
|
+
return `๐ Ocean connected: ${project}`;
|
|
15
|
+
}
|
|
16
|
+
export async function readVisibility() {
|
|
17
|
+
try {
|
|
18
|
+
const value = JSON.parse(await readFile(visibilityFile(), "utf8"));
|
|
19
|
+
const folders = value?.folders && typeof value.folders === "object"
|
|
20
|
+
? value.folders
|
|
21
|
+
: {};
|
|
22
|
+
return {
|
|
23
|
+
folders,
|
|
24
|
+
...(typeof value?.syncedAt === "string"
|
|
25
|
+
? { syncedAt: value.syncedAt }
|
|
26
|
+
: {}),
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
catch {
|
|
30
|
+
return { folders: {} };
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
// Never throws: a session starts and a sync finishes whether or not this could be noted.
|
|
34
|
+
async function updateVisibility(change) {
|
|
35
|
+
const file = visibilityFile();
|
|
36
|
+
try {
|
|
37
|
+
await mkdir(path.dirname(file), { recursive: true, mode: 0o700 });
|
|
38
|
+
await withFileLock(file, async () => {
|
|
39
|
+
const next = change(await readVisibility());
|
|
40
|
+
await writeFile(file, `${JSON.stringify(next, null, 2)}\n`, {
|
|
41
|
+
mode: 0o600,
|
|
42
|
+
});
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
catch {
|
|
46
|
+
// the next start or sync tries again
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
export async function recordConnected(cwd, project, now = new Date()) {
|
|
50
|
+
const folder = path.resolve(cwd);
|
|
51
|
+
await updateVisibility((state) => {
|
|
52
|
+
const folders = { ...state.folders };
|
|
53
|
+
delete folders[folder];
|
|
54
|
+
folders[folder] = { project, at: now.toISOString() };
|
|
55
|
+
// Newest last; keep only the most recent folders so the file stays small.
|
|
56
|
+
const kept = Object.entries(folders)
|
|
57
|
+
.sort(([, a], [, b]) => a.at.localeCompare(b.at))
|
|
58
|
+
.slice(-VISIBILITY_MAX_FOLDERS);
|
|
59
|
+
return { ...state, folders: Object.fromEntries(kept) };
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
export async function recordSynced(now = new Date()) {
|
|
63
|
+
await updateVisibility((state) => ({
|
|
64
|
+
...state,
|
|
65
|
+
syncedAt: now.toISOString(),
|
|
66
|
+
}));
|
|
67
|
+
}
|
|
68
|
+
//# sourceMappingURL=visibility.js.map
|
|
@@ -7,6 +7,7 @@ import { recordIssuedAck } from "@ocean/core/shared/context-ack.js";
|
|
|
7
7
|
import { truncateUtf8 } from "@ocean/core/shared/fs-utils.js";
|
|
8
8
|
import { oceanRoot, SYSTEM_DIR } from "@ocean/core/shared/paths.js";
|
|
9
9
|
import { autoRegisterProject, gitChangedFiles, projectRules, readProjectManifest, resolveProject, scanProjectManifests, } from "@ocean/core/shared/project-resolution.js";
|
|
10
|
+
import { connectedLine, recordConnected, } from "@ocean/core/shared/visibility.js";
|
|
10
11
|
const MAX_STDIN_BYTES = 65_536;
|
|
11
12
|
export async function readBoundedStdin(stream = process.stdin, maxBytes = MAX_STDIN_BYTES) {
|
|
12
13
|
if (stream.isTTY)
|
|
@@ -124,7 +125,11 @@ export async function claudeSessionStartHook(payload) {
|
|
|
124
125
|
rulesProblem = error instanceof Error ? error.message : String(error);
|
|
125
126
|
}
|
|
126
127
|
const bootstrap = buildOceanBootstrap(project, { rules: rules.length });
|
|
127
|
-
|
|
128
|
+
const shown = project.status === "bound" ? project.projectId : project.status;
|
|
129
|
+
await Promise.all([
|
|
130
|
+
recordIssuedAck(bootstrap.ack),
|
|
131
|
+
recordConnected(cwd, shown),
|
|
132
|
+
]);
|
|
128
133
|
// Beside the 256-byte bootstrap, never inside it: the authority claim is its own line.
|
|
129
134
|
const parts = [bootstrap.content, MEMORY_AUTHORITY_LINE];
|
|
130
135
|
if (project.status === "bound" && rules.length)
|
|
@@ -140,6 +145,7 @@ export async function claudeSessionStartHook(payload) {
|
|
|
140
145
|
if (warning)
|
|
141
146
|
parts.push(warning);
|
|
142
147
|
return {
|
|
148
|
+
systemMessage: connectedLine(shown),
|
|
143
149
|
hookSpecificOutput: {
|
|
144
150
|
hookEventName: "SessionStart",
|
|
145
151
|
additionalContext: parts.join("\n"),
|
|
@@ -872,7 +872,13 @@ export async function handleOceanMcpRequest(request, ports) {
|
|
|
872
872
|
result: {
|
|
873
873
|
protocolVersion: "2025-06-18",
|
|
874
874
|
capabilities: { tools: {}, resources: {}, prompts: {} },
|
|
875
|
-
|
|
875
|
+
// `name` is the machine id; `title` (MCP 2025-06-18) is the one display name every
|
|
876
|
+
// client shows, under the one config key `ocean` โ tool prefix `mcp__ocean__` (T-328).
|
|
877
|
+
serverInfo: {
|
|
878
|
+
name: "ocean",
|
|
879
|
+
title: "Ocean",
|
|
880
|
+
version: await serverVersion(),
|
|
881
|
+
},
|
|
876
882
|
instructions: MEMORY_INSTRUCTIONS,
|
|
877
883
|
},
|
|
878
884
|
};
|
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.22.0",
|
|
9
9
|
"engines": {
|
|
10
|
-
"ocean": ">=2.
|
|
10
|
+
"ocean": ">=2.22.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.22.0",
|
|
27
27
|
"engines": {
|
|
28
|
-
"ocean": ">=2.
|
|
28
|
+
"ocean": ">=2.22.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.22.0",
|
|
45
45
|
"engines": {
|
|
46
|
-
"ocean": ">=2.
|
|
46
|
+
"ocean": ">=2.22.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.22.0",
|
|
63
63
|
"engines": {
|
|
64
|
-
"ocean": ">=2.
|
|
64
|
+
"ocean": ">=2.22.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.22.0",
|
|
81
81
|
"engines": {
|
|
82
|
-
"ocean": ">=2.
|
|
82
|
+
"ocean": ">=2.22.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.22.0",
|
|
99
99
|
"engines": {
|
|
100
|
-
"ocean": ">=2.
|
|
100
|
+
"ocean": ">=2.22.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.22.0",
|
|
117
117
|
"engines": {
|
|
118
|
-
"ocean": ">=2.
|
|
118
|
+
"ocean": ">=2.22.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.22.0",
|
|
135
135
|
"engines": {
|
|
136
|
-
"ocean": ">=2.
|
|
136
|
+
"ocean": ">=2.22.0"
|
|
137
137
|
},
|
|
138
138
|
"source": {
|
|
139
139
|
"type": "path",
|
|
@@ -149,16 +149,16 @@
|
|
|
149
149
|
{
|
|
150
150
|
"kind": "skill",
|
|
151
151
|
"name": "dev.ocean.skills.ocean-memory",
|
|
152
|
-
"version": "2.
|
|
152
|
+
"version": "2.22.0",
|
|
153
153
|
"engines": {
|
|
154
|
-
"ocean": ">=2.
|
|
154
|
+
"ocean": ">=2.22.0"
|
|
155
155
|
},
|
|
156
156
|
"source": {
|
|
157
157
|
"type": "path",
|
|
158
158
|
"path": "skills/core/ocean-memory"
|
|
159
159
|
},
|
|
160
160
|
"integrity": {
|
|
161
|
-
"sha256": "
|
|
161
|
+
"sha256": "c001b4fdf8afe2e52b5b8a1fea6311584da4b62146e99e7244cc29807ad98365"
|
|
162
162
|
},
|
|
163
163
|
"spec": {
|
|
164
164
|
"directory": "ocean-memory"
|
|
@@ -167,9 +167,9 @@
|
|
|
167
167
|
{
|
|
168
168
|
"kind": "skill",
|
|
169
169
|
"name": "dev.ocean.skills.session-handoff",
|
|
170
|
-
"version": "2.
|
|
170
|
+
"version": "2.22.0",
|
|
171
171
|
"engines": {
|
|
172
|
-
"ocean": ">=2.
|
|
172
|
+
"ocean": ">=2.22.0"
|
|
173
173
|
},
|
|
174
174
|
"source": {
|
|
175
175
|
"type": "path",
|
|
@@ -185,9 +185,9 @@
|
|
|
185
185
|
{
|
|
186
186
|
"kind": "skill",
|
|
187
187
|
"name": "dev.ocean.skills.use-browser",
|
|
188
|
-
"version": "2.
|
|
188
|
+
"version": "2.22.0",
|
|
189
189
|
"engines": {
|
|
190
|
-
"ocean": ">=2.
|
|
190
|
+
"ocean": ">=2.22.0"
|
|
191
191
|
},
|
|
192
192
|
"source": {
|
|
193
193
|
"type": "path",
|
|
@@ -203,9 +203,9 @@
|
|
|
203
203
|
{
|
|
204
204
|
"kind": "skill",
|
|
205
205
|
"name": "dev.ocean.skills.verification",
|
|
206
|
-
"version": "2.
|
|
206
|
+
"version": "2.22.0",
|
|
207
207
|
"engines": {
|
|
208
|
-
"ocean": ">=2.
|
|
208
|
+
"ocean": ">=2.22.0"
|
|
209
209
|
},
|
|
210
210
|
"source": {
|
|
211
211
|
"type": "path",
|
|
@@ -221,9 +221,9 @@
|
|
|
221
221
|
{
|
|
222
222
|
"kind": "skill",
|
|
223
223
|
"name": "dev.ocean.skills.weekly-review",
|
|
224
|
-
"version": "2.
|
|
224
|
+
"version": "2.22.0",
|
|
225
225
|
"engines": {
|
|
226
|
-
"ocean": ">=2.
|
|
226
|
+
"ocean": ">=2.22.0"
|
|
227
227
|
},
|
|
228
228
|
"source": {
|
|
229
229
|
"type": "path",
|
|
@@ -276,9 +276,9 @@
|
|
|
276
276
|
"npx"
|
|
277
277
|
]
|
|
278
278
|
},
|
|
279
|
-
"version": "2.
|
|
279
|
+
"version": "2.22.0",
|
|
280
280
|
"engines": {
|
|
281
|
-
"ocean": ">=2.
|
|
281
|
+
"ocean": ">=2.22.0"
|
|
282
282
|
},
|
|
283
283
|
"source": {
|
|
284
284
|
"type": "path",
|
|
@@ -397,9 +397,9 @@
|
|
|
397
397
|
"npx"
|
|
398
398
|
]
|
|
399
399
|
},
|
|
400
|
-
"version": "2.
|
|
400
|
+
"version": "2.22.0",
|
|
401
401
|
"engines": {
|
|
402
|
-
"ocean": ">=2.
|
|
402
|
+
"ocean": ">=2.22.0"
|
|
403
403
|
},
|
|
404
404
|
"source": {
|
|
405
405
|
"type": "path",
|
|
@@ -463,9 +463,9 @@
|
|
|
463
463
|
"kind": "mcp",
|
|
464
464
|
"name": "dev.ocean/mcp-gateway",
|
|
465
465
|
"description": "One MCP endpoint for every registered server: Ocean's own and those installed from the marketplace.",
|
|
466
|
-
"version": "2.
|
|
466
|
+
"version": "2.22.0",
|
|
467
467
|
"engines": {
|
|
468
|
-
"ocean": ">=2.
|
|
468
|
+
"ocean": ">=2.22.0"
|
|
469
469
|
},
|
|
470
470
|
"source": {
|
|
471
471
|
"type": "path",
|
|
@@ -507,9 +507,9 @@
|
|
|
507
507
|
"kind": "mcp",
|
|
508
508
|
"name": "dev.ocean/obsidian",
|
|
509
509
|
"description": "Ocean's Obsidian vault bridge over MCP.",
|
|
510
|
-
"version": "2.
|
|
510
|
+
"version": "2.22.0",
|
|
511
511
|
"engines": {
|
|
512
|
-
"ocean": ">=2.
|
|
512
|
+
"ocean": ">=2.22.0"
|
|
513
513
|
},
|
|
514
514
|
"source": {
|
|
515
515
|
"type": "path",
|
|
@@ -551,9 +551,9 @@
|
|
|
551
551
|
"kind": "mcp",
|
|
552
552
|
"name": "dev.ocean/ocean",
|
|
553
553
|
"description": "Ocean's own MCP server: workspace status, tasks, handoffs, sessions and the brain.",
|
|
554
|
-
"version": "2.
|
|
554
|
+
"version": "2.22.0",
|
|
555
555
|
"engines": {
|
|
556
|
-
"ocean": ">=2.
|
|
556
|
+
"ocean": ">=2.22.0"
|
|
557
557
|
},
|
|
558
558
|
"source": {
|
|
559
559
|
"type": "path",
|
|
@@ -605,9 +605,9 @@
|
|
|
605
605
|
"npx"
|
|
606
606
|
]
|
|
607
607
|
},
|
|
608
|
-
"version": "2.
|
|
608
|
+
"version": "2.22.0",
|
|
609
609
|
"engines": {
|
|
610
|
-
"ocean": ">=2.
|
|
610
|
+
"ocean": ">=2.22.0"
|
|
611
611
|
},
|
|
612
612
|
"source": {
|
|
613
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.22.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.22.0",
|
|
57
|
+
"@ocean/context": "2.22.0",
|
|
58
|
+
"@ocean/core": "2.22.0",
|
|
59
|
+
"@ocean/loop": "2.22.0",
|
|
60
|
+
"@ocean/market": "2.22.0",
|
|
61
|
+
"@ocean/services": "2.22.0",
|
|
62
62
|
"playwright-core": "^1.48.0",
|
|
63
63
|
"sqlite-vec": "0.1.9",
|
|
64
64
|
"zod": "^4.6.5"
|
|
@@ -19,6 +19,11 @@ remember:
|
|
|
19
19
|
3. Asked where memory lives, say in one sentence that it lives in Ocean on their
|
|
20
20
|
own computer, and that your built-in memory is only a copy of it.
|
|
21
21
|
|
|
22
|
+
Show the user that Ocean is on: the first reply in a conversation where you call an
|
|
23
|
+
`ocean` tool begins with one line of its own, `๐ Ocean ยท <project>`, naming the project
|
|
24
|
+
the Ocean start line or `ocean_context` gives, or just `๐ Ocean` when none is named.
|
|
25
|
+
Once per conversation, never again after that.
|
|
26
|
+
|
|
22
27
|
When the user states a decision, preference or correction, call `memory_propose`.
|
|
23
28
|
Use `memory_write` only when they explicitly ask you to remember or change something.
|
|
24
29
|
|