pantheon-cli 0.2.18 → 0.2.19

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.
Files changed (2) hide show
  1. package/dist/pantheon.mjs +22 -7
  2. package/package.json +1 -1
package/dist/pantheon.mjs CHANGED
@@ -22892,13 +22892,15 @@ function resumeNote(sessions, turns, story, skills) {
22892
22892
  return parts.join(" ");
22893
22893
  }
22894
22894
  function readResume(home, space) {
22895
- const { slug, root } = resolveForRead(home, space);
22895
+ const { slug, root, shared, owner } = resolveForRead(home, space);
22896
22896
  const sessions = sessionSummaries(root);
22897
22897
  const turns = sessions.reduce((sum, session) => sum + session.turns, 0);
22898
22898
  const story = readStory(root);
22899
22899
  const skills = skillRefs(root);
22900
+ const borrowed = shared ? `This conscience belongs to @${owner} and was shared with you to read. Nothing can be written to it \u2014 when this chat ends, hand off to one of your own spaces. ` : "";
22900
22901
  return {
22901
22902
  space: slug,
22903
+ ...shared ? { shared, owner } : {},
22902
22904
  handoff: readText(join3(root, "handoff.md")).trim() || "(empty handoff)",
22903
22905
  memory: readText(join3(root, "memory.md")).trim() || "(no durable memory yet)",
22904
22906
  sessionId: sessions[0]?.id ?? null,
@@ -22908,7 +22910,7 @@ function readResume(home, space) {
22908
22910
  artifacts: listSpaceArtifacts(root),
22909
22911
  skills,
22910
22912
  pendingSkills: listSkills(root, "draft").length,
22911
- note: resumeNote(sessions, turns, story.length, skills)
22913
+ note: borrowed + resumeNote(sessions, turns, story.length, skills)
22912
22914
  };
22913
22915
  }
22914
22916
  function packetPreview(markdown) {
@@ -23473,7 +23475,7 @@ ${GUIDE}` }]
23473
23475
  registerTool(
23474
23476
  server,
23475
23477
  "pantheon_list_spaces",
23476
- "List existing Pantheon consciences from the private vault. Trigger: /pantheon-spaces. For listing only \u2014 never invent extra names. If the human already typed a new slug for handoff, do not block that handoff because it is missing here.",
23478
+ "List existing Pantheon consciences from the private vault. Trigger: /pantheon-spaces. For listing only \u2014 never invent extra names. If the human already typed a new slug for handoff, do not block that handoff because it is missing here. An entry with shared: true belongs to another person and is named owner/slug: it can be resumed and searched, but never handed off to, parked in, or remembered into. Say whose it is when you show the list.",
23477
23479
  {},
23478
23480
  async () => safe(async () => {
23479
23481
  const sync2 = await vault.pull(home);
@@ -23489,7 +23491,7 @@ ${GUIDE}` }]
23489
23491
  registerTool(
23490
23492
  server,
23491
23493
  "pantheon_resume",
23492
- "Pull the vault, then load a Pantheon conscience: the latest handoff packet, durable memory, packets from earlier handoffs (story), every archived session with its turn count (sessions), and stored artifact names. Trigger: /pantheon-resume <space>. If the space name is missing or empty, this tool lists live spaces \u2014 show that list and ask which conscience. The packet is a summary of the session that ended last, not the space: when the human asks about anything it does not cover, call pantheon_search before saying you lack context, and read detail with pantheon_get_turns or pantheon_get_session using any id from sessions. Fetch files with pantheon_get_artifact. Never call a generic resume tool for this. Do not run pantheon sync. REPORT THE RESULT as a two-column table \u2014 space, sessions (with total turns), earlier handoffs, memory facts, artifacts, skills (live and awaiting review), pulled \u2014 and then, outside the table, two or three sentences on where the work actually stood, any open threads, and the available skills by name and trigger. The table proves the load worked; it does not tell the human where the work was, so never collapse that prose into cells.",
23494
+ "Pull the vault, then load a Pantheon conscience: the latest handoff packet, durable memory, packets from earlier handoffs (story), every archived session with its turn count (sessions), and stored artifact names. Trigger: /pantheon-resume <space>. If the space name is missing or empty, this tool lists live spaces \u2014 show that list and ask which conscience. The packet is a summary of the session that ended last, not the space: when the human asks about anything it does not cover, call pantheon_search before saying you lack context, and read detail with pantheon_get_turns or pantheon_get_session using any id from sessions. Fetch files with pantheon_get_artifact. Never call a generic resume tool for this. Do not run pantheon sync. A space named owner/slug was shared with you by someone else: resume and search work, writing does not, so tell the human at the end that this chat has to be handed off to one of their own spaces. REPORT THE RESULT as a two-column table \u2014 space, sessions (with total turns), earlier handoffs, memory facts, artifacts, skills (live and awaiting review), pulled \u2014 and then, outside the table, two or three sentences on where the work actually stood, any open threads, and the available skills by name and trigger. The table proves the load worked; it does not tell the human where the work was, so never collapse that prose into cells.",
23493
23495
  { space: external_exports.string().optional() },
23494
23496
  async ({ space }) => safe(async () => {
23495
23497
  const sync2 = await vault.pull(home);
@@ -23505,9 +23507,22 @@ ${GUIDE}` }]
23505
23507
  sync: sync2
23506
23508
  };
23507
23509
  }
23508
- const match = spaces.find(
23509
- (item) => item.slug === raw || item.slug === raw.toLowerCase() || item.title === raw
23510
+ const lower = raw.toLowerCase();
23511
+ const exact = spaces.find(
23512
+ (item) => item.slug === raw || item.slug === lower || item.title === raw
23510
23513
  );
23514
+ const bare = exact ? [] : spaces.filter((item) => item.shared && item.slug.split("/")[1] === lower);
23515
+ if (bare.length > 1) {
23516
+ return {
23517
+ needSpace: true,
23518
+ home,
23519
+ spaces,
23520
+ source: "pantheon vault",
23521
+ note: `"${raw}" has been shared with you by more than one person: ${bare.map((item) => item.slug).join(", ")}. Ask which one they mean, then call pantheon_resume with the full name.`,
23522
+ sync: sync2
23523
+ };
23524
+ }
23525
+ const match = exact || bare[0];
23511
23526
  if (!match) {
23512
23527
  return {
23513
23528
  needSpace: true,
@@ -24154,7 +24169,7 @@ function detectApps() {
24154
24169
  }
24155
24170
  var AHEAD = "Written ahead \u2014 app not detected, ready if you install it";
24156
24171
  function nextSteps(found, apiUrl) {
24157
- if (found.length) return " Reload MCP in each app, then type /pantheon-handoff <space>";
24172
+ if (found.length) return "Reload MCP in each app, then type /pantheon-handoff <space>";
24158
24173
  return [
24159
24174
  " No desktop agent detected. The configs above are in place if you install one.",
24160
24175
  "",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pantheon-cli",
3
- "version": "0.2.18",
3
+ "version": "0.2.19",
4
4
  "description": "Carry agent conscience between AI coding agents. Hand off a conversation in one agent, resume it in another.",
5
5
  "license": "MIT",
6
6
  "type": "module",