[GH-ISSUE #1854] [Feature]: Long-Term Memory: offer to turn on Slurp's memory switch after sharing is turned on #1787

Closed
opened 2026-11-07 16:36:40 +07:00 by bsakaguchi · 0 comments
Owner

Originally created by @Promansis on GitHub (Oct 29, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Agents/issues/1854

Originally assigned to: @Promansis on GitHub.

What problem does this solve?

Slurp's Creators use LTM memories (#1841, Slurp 0.4.9) only when both switches are on: LTM's "Other Agents can read
memories" (longTermMemoryShareWithPackages) and Slurp's "What your other Agents know" (flavourFromAgents). A player
who turns LTM sharing on while Slurp's switch is off sees nothing happen. They have to know to open Slurp → Backstage →
Engine link.

Proposed package or change

When a Save in Memory Settings changes "Other Agents can read memories" from off to on, LTM checks Slurp's switch.
If Slurp is installed and its switch is off, LTM asks (wording approved by the maintainer on 2026-10-29):

Turn on memories in Slurp?
Slurp's "What your other Agents know" switch is off, so its Creators won't use these memories. Turn it on for you? It
also lets Creators read Character Tracker, World State and Persona Stats.
[Not now] [Turn it on]

  • The offer comes after a successful Save, not when the toggle flips. The toggle only edits the form, so asking on
    the flip and then Discarding would leave Slurp changed while LTM sharing stayed off.
  • "Turn it on" saves { flavourFromAgents: true } to Slurp. "Not now" leaves Slurp alone, and LTM's saved setting stays
    on either way.
  • No popup when Slurp is not installed or the read fails, when Slurp's switch is already on, or when the save did not
    change sharing from off to on. Reset and Import do not count as that Save.

Minimal fix

  1. New packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/settings/slurp-memory-offer.ts:
    export offerSlurpMemories({ read, confirm, save }) with injected dependencies, using the same contract as Slurp's
    offerLtmSharing.
    • Call read() first. If it throws, return "skipped". If the result has flavourFromAgents !== false, also return
      "skipped".
    • Otherwise call confirm(). If it returns false, return "declined".
    • Otherwise call await save() and return "enabled".
  2. MemorySettings.tsx saveSettings (around lines 335-394):
    • Before the PUT, record whether the saved form had longTermMemoryShareWithPackages off.
    • After a successful global save whose saved.longTermMemoryShareWithPackages is true, call offerSlurpMemories with:
      • read: requestHost("/api/slurp2/settings") (api.ts:200).
      • confirm: the existing confirm(props, …) helper.
      • save: a PATCH to /api/slurp2/settings with the same admin-secret and CSRF headers request sends.
        requestHost is GET-only today; give it optional method/body instead of adding a new helper.
    • A failed Slurp save shows through the existing setMessage(…, "danger", surface). The LTM save is still reported
      as saved.
  3. settings/settings-shared.tsx confirm() and types.ts:41 confirmAction: add an optional cancelLabel and pass
    it through, so the popup reads "Not now". Engine already passes its own showConfirmDialog as confirmAction
    (AppShell.tsx:881, ChatSettingsDrawer.tsx:1587), and that accepts cancelLabel. No Engine change.
  4. locales/en.json and ko.json: add ui.longTermMemory.memorysettings.slurpMemoryOfferTitle, …OfferMessage,
    …OfferConfirm ("Turn it on") and …OfferCancel ("Not now"). Run
    node scripts/validate-package-locales.mjs.
  5. packages/long-term-memory/CHANGELOG.md: one line under ## Unreleased. No version bump; reland.mjs sets it at
    land (patch).

LTM names Slurp here for the first time in its client. This is deliberate: the maintainer asked for this pair to link,
and the offer only appears once Slurp's route answers.

Proof

  • tests/long-term-memory-debug-activity.regression.ts already imports LTM settings client modules. Add the four
    offerSlurpMemories cases there: off and confirmed → save once, "enabled"; declined → no save; already on → no
    confirm; read throws → no confirm.
  • Add a source pin that saveSettings calls it only after the global PUT and only on an off→on change.
  • Run the affected suites with test-ltm.sh (MARINARA_AGENTS_ROOT and MARINARA_ENGINE_ROOT set), the
    long-term-memory-host-styles check before push, test-fast.sh, npm run check and the locale validator.

Why should this be optional?

It is a one-time question inside an existing package setting and changes no behavior until the player says yes. Nothing is added to the Engine core.

Alternatives considered

Non-goals:

  • Turning Slurp's switch off when LTM sharing goes off.
  • Offers for Noodle or other readers. Today Noodle does not call LTM's services.
  • Any Engine change, and any new Slurp route. Slurp's existing PATCH /settings is enough.

Additional context

Pair: #1853 (the same popup from the Slurp side). The two ship as separate PRs and share no files.

Template check

  • I DID NOT read this template and provide the requested details.
Originally created by @Promansis on GitHub (Oct 29, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Agents/issues/1854 Originally assigned to: @Promansis on GitHub. ## What problem does this solve? Slurp's Creators use LTM memories (#1841, Slurp 0.4.9) only when both switches are on: LTM's "Other Agents can read memories" (`longTermMemoryShareWithPackages`) and Slurp's "What your other Agents know" (`flavourFromAgents`). A player who turns LTM sharing on while Slurp's switch is off sees nothing happen. They have to know to open Slurp → Backstage → Engine link. ## Proposed package or change When a **Save** in Memory Settings changes "Other Agents can read memories" from off to on, LTM checks Slurp's switch. If Slurp is installed and its switch is off, LTM asks (wording approved by the maintainer on 2026-10-29): > **Turn on memories in Slurp?** > Slurp's "What your other Agents know" switch is off, so its Creators won't use these memories. Turn it on for you? It > also lets Creators read Character Tracker, World State and Persona Stats. > [Not now] [Turn it on] - The offer comes **after a successful Save**, not when the toggle flips. The toggle only edits the form, so asking on the flip and then Discarding would leave Slurp changed while LTM sharing stayed off. - "Turn it on" saves `{ flavourFromAgents: true }` to Slurp. "Not now" leaves Slurp alone, and LTM's saved setting stays on either way. - No popup when Slurp is not installed or the read fails, when Slurp's switch is already on, or when the save did not change sharing from off to on. Reset and Import do not count as that Save. ### Minimal fix 1. New `packages/long-term-memory/src/engine/packages/client/src/features/long-term-memory/settings/slurp-memory-offer.ts`: export `offerSlurpMemories({ read, confirm, save })` with injected dependencies, using the same contract as Slurp's `offerLtmSharing`. - Call `read()` first. If it throws, return `"skipped"`. If the result has `flavourFromAgents !== false`, also return `"skipped"`. - Otherwise call `confirm()`. If it returns false, return `"declined"`. - Otherwise call `await save()` and return `"enabled"`. 2. `MemorySettings.tsx` `saveSettings` (around lines 335-394): - Before the PUT, record whether the saved form had `longTermMemoryShareWithPackages` off. - After a successful global save whose `saved.longTermMemoryShareWithPackages` is true, call `offerSlurpMemories` with: - `read`: `requestHost("/api/slurp2/settings")` (`api.ts:200`). - `confirm`: the existing `confirm(props, …)` helper. - `save`: a PATCH to `/api/slurp2/settings` with the same admin-secret and CSRF headers `request` sends. `requestHost` is GET-only today; give it optional `method`/`body` instead of adding a new helper. - A failed Slurp save shows through the existing `setMessage(…, "danger", surface)`. The LTM save is still reported as saved. 3. `settings/settings-shared.tsx` `confirm()` and `types.ts:41` `confirmAction`: add an optional `cancelLabel` and pass it through, so the popup reads "Not now". Engine already passes its own `showConfirmDialog` as `confirmAction` (`AppShell.tsx:881`, `ChatSettingsDrawer.tsx:1587`), and that accepts `cancelLabel`. No Engine change. 4. `locales/en.json` and `ko.json`: add `ui.longTermMemory.memorysettings.slurpMemoryOfferTitle`, `…OfferMessage`, `…OfferConfirm` ("Turn it on") and `…OfferCancel` ("Not now"). Run `node scripts/validate-package-locales.mjs`. 5. `packages/long-term-memory/CHANGELOG.md`: one line under `## Unreleased`. No version bump; `reland.mjs` sets it at land (patch). LTM names Slurp here for the first time in its client. This is deliberate: the maintainer asked for this pair to link, and the offer only appears once Slurp's route answers. ### Proof - `tests/long-term-memory-debug-activity.regression.ts` already imports LTM settings client modules. Add the four `offerSlurpMemories` cases there: off and confirmed → `save` once, `"enabled"`; declined → no `save`; already on → no `confirm`; `read` throws → no `confirm`. - Add a source pin that `saveSettings` calls it only after the global PUT and only on an off→on change. - Run the affected suites with `test-ltm.sh` (MARINARA_AGENTS_ROOT and MARINARA_ENGINE_ROOT set), the `long-term-memory-host-styles` check before push, `test-fast.sh`, `npm run check` and the locale validator. ## Why should this be optional? It is a one-time question inside an existing package setting and changes no behavior until the player says yes. Nothing is added to the Engine core. ## Alternatives considered Non-goals: - Turning Slurp's switch **off** when LTM sharing goes off. - Offers for Noodle or other readers. Today Noodle does not call LTM's services. - Any Engine change, and any new Slurp route. Slurp's existing `PATCH /settings` is enough. ## Additional context Pair: #1853 (the same popup from the Slurp side). The two ship as separate PRs and share no files. ## Template check - [ ] I DID NOT read this template and provide the requested details.
bsakaguchi 2026-11-07 16:36:40 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Agents#1787
No description provided.