overlord-cli 0.2610242007.0 → 0.2610281354.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.
@@ -9,6 +9,7 @@ OpenCode, Antigravity, and others). A connector is what lets an agent speak the
9
9
  - [For Users](#for-users)
10
10
  - [Setting up connectors](#setting-up-connectors)
11
11
  - [Connector bundles](#connector-bundles)
12
+ - [Plugin marketplace](#plugin-marketplace)
12
13
  - [Extension point](#extension-point)
13
14
  - [For Developers](#for-developers)
14
15
  - [Contract Component](#contract-component)
@@ -41,6 +42,19 @@ connector contract version changes.
41
42
  - [Antigravity](adapters/antigravity/README.md): Antigravity plugin exposing the local mission workflow to Antigravity CLI/IDE sessions.
42
43
  - [OpenCode](adapters/opencode/README.md): control-plane connector (Shape C) driven by `ovld agent-session sidecar` — no hook scripts.
43
44
 
45
+ ### Plugin marketplace
46
+
47
+ The dedicated [Overlord ecosystem marketplace](https://github.com/cooperativ-labs/overlord-marketplace#readme)
48
+ is intended to distribute the optional Knowledgebase plugin for Codex CLI and
49
+ Claude Code. Publication and public first-install verification are pending; consult
50
+ its README for the current status and installation and refresh instructions. Knowledgebase
51
+ also supports MCP-only use; its onboarding changes are tracked in per:214.
52
+
53
+ Continue to install and refresh Overlord itself with `ovld agent-setup <agent>`.
54
+ That setup owns its existing hooks and, for Codex, rules and permission profile.
55
+ The new marketplace's v1 scope does not include Overlord or Scribe and does not
56
+ migrate existing installations.
57
+
44
58
  ### Extension point
45
59
 
46
60
  A custom agent connector is a sanctioned extension point: a new adapter plus a
@@ -1 +1 @@
1
- 0.3.57
1
+ 0.3.58
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://antigravity.google/schemas/v1/plugin.json",
3
3
  "name": "overlord",
4
- "version": "0.3.57",
4
+ "version": "0.3.58",
5
5
  "description": "Chat-driven access to Overlord mission protocol workflows through skills and MCP.",
6
6
  "author": {
7
7
  "name": "Cooperativ",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "overlord",
3
- "version": "0.3.57",
3
+ "version": "0.3.58",
4
4
  "description": "Overlord mission protocol workflow for Claude Code — attach/update/ask/deliver, slash commands, and hook-driven activity capture.",
5
5
  "author": {
6
6
  "name": "Cooperativ",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "overlord",
3
- "version": "0.3.57",
3
+ "version": "0.3.58",
4
4
  "description": "Chat-driven access to Overlord mission protocol workflows with hook-driven activity capture.",
5
5
  "author": {
6
6
  "name": "Cooperativ",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "overlord",
3
- "version": "0.3.57",
3
+ "version": "0.3.58",
4
4
  "description": "Overlord mission protocol workflow for Cursor — attach/update/ask/deliver, slash commands, MCP bridge, and follow-up capture.",
5
5
  "author": {
6
6
  "name": "Cooperativ",
@@ -26,11 +26,10 @@ Re-running setup is idempotent. `ovld doctor` reports missing or modified manage
26
26
 
27
27
  PI accepts provider-qualified models with `--model` and an independent `--thinking` level. The built-in catalog includes:
28
28
 
29
- | Display name | PI model ID |
30
- | --------------- | ---------------------------- |
31
- | GLM 5.2 | `zai/glm-5.2` |
32
- | Claude Opus 4.8 | `anthropic/claude-opus-4-8` |
33
- | GPT-5.6 Terra | `openai-codex/gpt-5.6-terra` |
29
+ | Display name | PI model ID |
30
+ | --------------- | --------------------------- |
31
+ | GLM 5.2 | `zai/glm-5.2` |
32
+ | Claude Opus 4.8 | `anthropic/claude-opus-4-8` |
34
33
 
35
34
  Authenticate the matching PI provider through PI's login/configuration flow or its supported environment variables. Use `pi --list-models` to inspect the models available to the current PI configuration.
36
35
 
@@ -389,7 +389,7 @@ ovld protocol create --project-id <project-id> --agent <agent-identifier> --obje
389
389
  # One call: a draft mission whose first objective is already assigned to Codex.
390
390
  ovld protocol create --agent <agent-identifier> \
391
391
  --project-id <project-id> \
392
- --objectives-json '[{"objective":"Implement the API","agent":"codex","model":"gpt-5.6-terra"},{"objective":"Add CLI docs","agent":"claude"}]'
392
+ --objectives-json '[{"objective":"Implement the API","agent":"codex","model":"gpt-6.1-terra"},{"objective":"Add CLI docs","agent":"claude"}]'
393
393
  ```
394
394
 
395
395
  ```bash
@@ -188,7 +188,7 @@ ovld protocol create --project-id <project-id> --agent <agent-identifier> --obje
188
188
  # One call: a draft mission whose first objective is already assigned to Codex.
189
189
  ovld protocol create --agent <agent-identifier> \
190
190
  --project-id <project-id> \
191
- --objectives-json '[{"objective":"Implement the API","agent":"codex","model":"gpt-5.6-terra"},{"objective":"Add CLI docs","agent":"claude"}]'
191
+ --objectives-json '[{"objective":"Implement the API","agent":"codex","model":"gpt-6.1-terra"},{"objective":"Add CLI docs","agent":"claude"}]'
192
192
  ```
193
193
 
194
194
  ```bash
@@ -1837,7 +1837,7 @@ process.stdin.on('data', async chunk => {
1837
1837
  result: {
1838
1838
  protocolVersion: PROTOCOL_VERSION,
1839
1839
  capabilities: { tools: { listChanged: false } },
1840
- serverInfo: { name: 'overlord-__OVERLORD_ADAPTER_KEY__', version: '0.3.57' }
1840
+ serverInfo: { name: 'overlord-__OVERLORD_ADAPTER_KEY__', version: '0.3.58' }
1841
1841
  }
1842
1842
  });
1843
1843
  continue;
package/dist/index.js CHANGED
@@ -5888,6 +5888,15 @@ function removeChangeLedger(input2) {
5888
5888
  return false;
5889
5889
  }
5890
5890
  }
5891
+ function prepareDeclaredChangeEvidence(input2) {
5892
+ const ledger = emptyLedger(input2);
5893
+ const result = appendEvidenceToLedger(ledger, {
5894
+ filePaths: input2.filePaths,
5895
+ source: "agent_declared",
5896
+ hookHealth: AGENT_DECLARED_HEALTH
5897
+ });
5898
+ return { evidence: ledger.evidence, rejected: result.rejected };
5899
+ }
5891
5900
  var LEDGER_SCHEMA_VERSION, MAX_PATHS_PER_APPEND, MAX_LEDGER_EVIDENCE, MAX_HEALTH_ENTRIES, STICKY_HEALTH_CODES, MAX_HEALTH_CODE_LENGTH, MAX_IGNORE_FILE_BYTES, MAX_IGNORE_LINES, MAX_IGNORE_RULES, MAX_IGNORE_LINE_LENGTH, MAX_LEDGER_FILE_BYTES, LEDGER_EVIDENCE_KEYS, LEDGER_HEALTH_KEYS, LEDGER_CAPTURE_KEYS, CAPTURE_BINDING_STATES, AGENT_DECLARED_HEALTH, LEGACY_GENERATOR_DECLARATION_HEALTH, LEGACY_WINDOW_DISCARDED_HEALTH, LEGACY_V2_EVIDENCE_KEYS;
5892
5901
  var init_change_ledger = __esm({
5893
5902
  "src/change-ledger.ts"() {
@@ -5934,6 +5943,7 @@ var init_change_ledger = __esm({
5934
5943
  var active_objective_sessions_exports = {};
5935
5944
  __export(active_objective_sessions_exports, {
5936
5945
  MAX_ACTIVE_OBJECTIVE_SESSION_BINDINGS: () => MAX_ACTIVE_OBJECTIVE_SESSION_BINDINGS,
5946
+ diagnoseObjectiveBinding: () => diagnoseObjectiveBinding,
5937
5947
  finalizeActiveSession: () => finalizeActiveSession,
5938
5948
  readActiveSessions: () => readActiveSessions,
5939
5949
  readObjectiveSessions: () => readObjectiveSessions,
@@ -5996,7 +6006,7 @@ function readManifest(workingDirectory) {
5996
6006
  const raw = readBoundedUtf8File(target, MAX_ACTIVE_SESSION_MANIFEST_BYTES);
5997
6007
  if (raw === null) return null;
5998
6008
  const value2 = JSON.parse(raw);
5999
- if (value2.schemaVersion !== 3 || value2.workingDirectory !== expected.workingDirectory || !Array.isArray(value2.entries) || value2.entries.length > MAX_ACTIVE_OBJECTIVE_SESSION_BINDINGS) {
6009
+ if (value2.schemaVersion !== 3 || value2.workingDirectory !== expected.workingDirectory || !Array.isArray(value2.entries)) {
6000
6010
  return null;
6001
6011
  }
6002
6012
  return {
@@ -6012,7 +6022,11 @@ function readManifest(workingDirectory) {
6012
6022
  }
6013
6023
  function writeManifest(workingDirectory, entries) {
6014
6024
  const manifest = { ...emptyManifest(workingDirectory), entries };
6015
- writeOwnerOnlyFileAtomically(manifestPath2(workingDirectory), JSON.stringify(manifest));
6025
+ const contents = JSON.stringify(manifest);
6026
+ if (Buffer.byteLength(contents) > MAX_ACTIVE_SESSION_MANIFEST_BYTES) {
6027
+ throw new Error("Local binding manifest exceeds its storage limit.");
6028
+ }
6029
+ writeOwnerOnlyFileAtomically(manifestPath2(workingDirectory), contents);
6016
6030
  }
6017
6031
  function resolveEntry(entries, requestedObjectiveId) {
6018
6032
  const matching = entries.filter(
@@ -6063,7 +6077,7 @@ function writeActiveSession({
6063
6077
  });
6064
6078
  if (!removed) entries.push({ ...prior, deliveryPendingSync: true });
6065
6079
  }
6066
- if (entries.length >= MAX_ACTIVE_OBJECTIVE_SESSION_BINDINGS) {
6080
+ if (entries.filter((entry) => entry.objectiveId === trimmedObjective).length >= MAX_ACTIVE_OBJECTIVE_SESSION_BINDINGS) {
6067
6081
  if (prior && prior.sessionKey !== trimmedKey) writeManifest(workingDirectory, entries);
6068
6082
  return false;
6069
6083
  }
@@ -6224,6 +6238,17 @@ function finalizeActiveSession({
6224
6238
  return false;
6225
6239
  }
6226
6240
  }
6241
+ function diagnoseObjectiveBinding(workingDirectory, objectiveId) {
6242
+ const target = manifestPath2(workingDirectory);
6243
+ if (!existsSync11(target)) return "binding_file_missing";
6244
+ const manifest = readManifest(workingDirectory);
6245
+ if (!manifest) return "binding_file_unreadable_or_invalid";
6246
+ const matches = manifest.entries.filter((entry) => entryMatchesObjective(entry, objectiveId));
6247
+ if (matches.length >= MAX_ACTIVE_OBJECTIVE_SESSION_BINDINGS)
6248
+ return "objective_binding_capacity_reached";
6249
+ if (matches.length === 0) return "objective_binding_missing_in_working_directory";
6250
+ return "binding_or_ledger_storage_unavailable";
6251
+ }
6227
6252
  var MAX_ACTIVE_OBJECTIVE_SESSION_BINDINGS, MAX_OBJECTIVE_ALIASES, MAX_ID_LENGTH, MAX_ACTIVE_SESSION_MANIFEST_BYTES, MAX_ACTIVE_SESSION_MANIFEST_FILES;
6228
6253
  var init_active_objective_sessions = __esm({
6229
6254
  "src/active-objective-sessions.ts"() {
@@ -44619,7 +44644,8 @@ function bareHealthCode(code) {
44619
44644
  function buildLocalObjectiveChanges({
44620
44645
  objectiveId,
44621
44646
  snapshots,
44622
- syncFailed
44647
+ syncFailed,
44648
+ unavailableDiagnosis = "objective_binding_missing_in_working_directory"
44623
44649
  }) {
44624
44650
  if (snapshots.length === 0) {
44625
44651
  return {
@@ -44631,8 +44657,12 @@ function buildLocalObjectiveChanges({
44631
44657
  limit: OBJECTIVE_FILE_CHANGES_LIMIT,
44632
44658
  truncated: false,
44633
44659
  sync: { synced: 0, pending: 0, failed: syncFailed },
44634
- capture: { bindingState: "unknown", callbackObserved: false, healthCodes: [] },
44635
- warnings: []
44660
+ capture: {
44661
+ bindingState: "unknown",
44662
+ callbackObserved: false,
44663
+ healthCodes: [unavailableDiagnosis]
44664
+ },
44665
+ warnings: ["unknown_binding"]
44636
44666
  };
44637
44667
  }
44638
44668
  const byPath = /* @__PURE__ */ new Map();
@@ -45344,7 +45374,7 @@ add-objectives:
45344
45374
  --objective-model requires --objective-agent.
45345
45375
  Notes:
45346
45376
  Each item is { "objective": "...", "title": "...", "agent": "codex",
45347
- "model": "gpt-5.6-terra", "autoAdvance": true|false, "resourceKey": "..." }.
45377
+ "model": "gpt-6.1-terra", "autoAdvance": true|false, "resourceKey": "..." }.
45348
45378
  model requires agent. Per-item autoAdvance and agent win over the flags.
45349
45379
 
45350
45380
  update-objective:
@@ -46943,10 +46973,14 @@ function declaredOutputPathInputs({
46943
46973
  }
46944
46974
  return paths;
46945
46975
  }
46946
- function appendDeclaredOutputPaths({
46976
+ async function appendDeclaredOutputPaths({
46947
46977
  flags,
46948
46978
  fileInputs,
46949
46979
  active,
46980
+ runtime,
46981
+ missionId,
46982
+ objectiveRef,
46983
+ sessionKey,
46950
46984
  workingDirectory
46951
46985
  }) {
46952
46986
  const paths = declaredOutputPathInputs({ flags, fileInputs });
@@ -46954,19 +46988,63 @@ function appendDeclaredOutputPaths({
46954
46988
  delete flags["--paths-file"];
46955
46989
  delete fileInputs["--paths-file"];
46956
46990
  if (paths === null) return;
46957
- if (!active) {
46991
+ if (!sessionKey || !active && !objectiveRef) {
46958
46992
  throw new CliError({
46959
- message: "--paths/--paths-file requires the attached objective session in this working directory."
46993
+ message: "--paths/--paths-file requires --session-key and --objective-id (or a cached attached session). Run protocol attach from this checkout."
46960
46994
  });
46961
46995
  }
46962
- const result = declareChangePaths({
46996
+ const identity = {
46963
46997
  workingDirectory,
46964
- objectiveId: active.objectiveId,
46965
- sessionKey: active.sessionKey,
46966
- filePaths: paths
46967
- });
46968
- if (!result.recorded) {
46969
- console.error("[overlord] Declared paths could not be recorded in the local change ledger.");
46998
+ objectiveId: active?.objectiveId ?? objectiveRef,
46999
+ sessionKey
47000
+ };
47001
+ const result = active ? declareChangePaths({ ...identity, filePaths: paths }) : null;
47002
+ if (!result?.recorded) {
47003
+ const prepared = prepareDeclaredChangeEvidence({ ...identity, filePaths: paths });
47004
+ console.error(
47005
+ `[overlord] ${diagnoseObjectiveBinding(workingDirectory, identity.objectiveId)}. Submitting declared paths directly through the authenticated session. Re-run protocol attach in this checkout; check OVLD_HOME permissions if capture remains unavailable.`
47006
+ );
47007
+ for (const rejected of prepared.rejected.slice(0, 20)) {
47008
+ console.error(
47009
+ `[overlord] Ignored declared path ${JSON.stringify(rejected.path)}: ${rejected.reason}`
47010
+ );
47011
+ }
47012
+ for (let offset = 0; offset < prepared.evidence.length; offset += 25) {
47013
+ const batch = prepared.evidence.slice(offset, offset + 25);
47014
+ try {
47015
+ const response = asRecord5(
47016
+ await runtime.backend.post({
47017
+ path: "/api/protocol/sync-changes",
47018
+ body: {
47019
+ args: [],
47020
+ positional: [],
47021
+ fileInputs: {},
47022
+ externalSessionId: null,
47023
+ flags: {
47024
+ "--mission-id": missionId,
47025
+ "--objective-id": identity.objectiveId,
47026
+ "--session-key": sessionKey,
47027
+ "--changes-json": JSON.stringify(batch)
47028
+ }
47029
+ }
47030
+ })
47031
+ );
47032
+ const outcomes = Array.isArray(response.outcomes) ? response.outcomes.map(asRecord5) : [];
47033
+ if (batch.some(
47034
+ (entry) => !outcomes.some(
47035
+ (outcome) => outcome.idempotencyKey === entry.idempotencyKey && outcome.filePath === entry.filePath && (outcome.status === "accepted" || outcome.status === "ignored")
47036
+ )
47037
+ )) {
47038
+ console.error(
47039
+ "[overlord] Some declared paths were not accepted. Retry --paths on update/deliver; no local retry copy is available."
47040
+ );
47041
+ }
47042
+ } catch {
47043
+ console.error(
47044
+ "[overlord] Declared path synchronization failed. Retry --paths on update/deliver; no local retry copy is available."
47045
+ );
47046
+ }
47047
+ }
46970
47048
  return;
46971
47049
  }
46972
47050
  for (const rejected of result.rejected.slice(0, 20)) {
@@ -47168,8 +47246,14 @@ Run \`${primaryCommand} protocol help\` for usage.`
47168
47246
  const local = buildLocalObjectiveChanges({
47169
47247
  objectiveId: objectiveSessions[0]?.objectiveId ?? objectiveRef,
47170
47248
  snapshots,
47171
- syncFailed
47249
+ syncFailed,
47250
+ unavailableDiagnosis: diagnoseObjectiveBinding(workingDirectory, objectiveRef)
47172
47251
  });
47252
+ if (local.coverage === "unavailable") {
47253
+ console.error(
47254
+ `[overlord] ${local.capture.healthCodes[0]}. Run protocol attach for this objective in this checkout and check OVLD_HOME permissions. Explicit --paths with a valid session key can still synchronize declarations.`
47255
+ );
47256
+ }
47173
47257
  for (const entry of objectiveSessions.filter((candidate) => candidate.deliveryPendingSync)) {
47174
47258
  const stillUnsynced = readUnsyncedChangeEvidence({
47175
47259
  workingDirectory,
@@ -47240,7 +47324,16 @@ Run \`${primaryCommand} protocol help\` for usage.`
47240
47324
  const sessionKey = typeof flags["--session-key"] === "string" ? flags["--session-key"] : null;
47241
47325
  const active = sessionKey ? readActiveSessions(workingDirectory).find((entry) => entry.sessionKey === sessionKey) : void 0;
47242
47326
  lifecycleActive = active;
47243
- appendDeclaredOutputPaths({ flags, fileInputs, active, workingDirectory });
47327
+ await appendDeclaredOutputPaths({
47328
+ flags,
47329
+ fileInputs,
47330
+ active,
47331
+ workingDirectory,
47332
+ runtime,
47333
+ missionId,
47334
+ objectiveRef,
47335
+ sessionKey
47336
+ });
47244
47337
  if (sessionKey && active) {
47245
47338
  await syncObjectiveLedger({ runtime, workingDirectory, missionId, sessionKey, active });
47246
47339
  }
@@ -47361,6 +47454,11 @@ Run \`${primaryCommand} protocol help\` for usage.`
47361
47454
  objectiveAliases: [...objectiveAliases],
47362
47455
  sessionKey: resultRecord.sessionKey
47363
47456
  });
47457
+ if (!bound) {
47458
+ console.error(
47459
+ `[overlord] Attach succeeded, but native file capture is unavailable: ${diagnoseObjectiveBinding(workingDirectory, objectiveIdentity)}. Check OVLD_HOME storage/permissions and re-run attach in this checkout. Explicit --paths can still synchronize through the session key.`
47460
+ );
47461
+ }
47364
47462
  if (bound) {
47365
47463
  recordChangeLedgerBinding({
47366
47464
  workingDirectory,