Skip to content

[Bug] Memory workflow only writes to sessions/<id>/ scratch path and never promotes to long-term data/memory/projects/ #415

Description

@Peefy

Describe the bug
The Memory Workflow generates a file like /Users/<user>/.openloomi/sessions/<session-id>/TN-Alpha-memory.md. To make it retrievable across sessions, the user has to manually copy that file into the long-term memory directory. Workflow success does not equal memory saved.

To Reproduce

  1. Ask OpenLoomi to remember project TN-Alpha.
  2. Run the memory workflow (or the memorize skill).
  3. Inspect the long-term project memory directory: data/memory/projects/ is empty.
  4. The file lives only under sessions/<id>/ and is invisible to future sessions.
  5. Restart / start a new session; the project memory is not retrieved.

Expected behavior
The workflow's "save" step should atomically promote its output to data/memory/projects/<slug>.md — the canonical long-term directory defined by apps/web/lib/ai/memory/fs-sync.ts:30. The slug is derived from the project name (stable, lowercase, ASCII-safe). Promotion should be part of the workflow's contract, not a separate manual action.

Screenshots
N/A

Desktop

  • OS: any
  • App: OpenLoomi desktop (Tauri) and web

Additional context

  • getMemoryFsPath() already returns the canonical long-term path; only the workflow's writer path is wrong.
  • Related: apps/web/lib/ai/memory/chat-sync.ts and the session-scoped helpers in the same folder need to be unified into one save flow that distinguishes "session draft" from "long-term memory".

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinghigh-priorityAlloomi high-prioritymemory

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions