# Chat with Memory (Phase 2) Implementation Plan
> **For Claude:** REQUIRED SUB-SKILL: Use superpowers:executing-plans or superpowers:subagent-driven-development to implement this plan task-by-task.
**Goal:** Add persistent memory to the chat interface using OpenViking's Session API, allowing conversations to be remembered across multiple runs with automatic memory extraction.
**Architecture:** Build on Phase 1 (examples/chat/), replace in-memory ChatSession with OpenViking Session API. Record all messages (user + assistant), commit session on exit (normal + Ctrl-C), load previous sessions on startup.
**Tech Stack:** Python 3.13+, Rich (TUI), OpenViking Session API, OpenViking SyncClient
Bug Description
Steps to Reproduce
file dir: /Users/xxx/code/OpenViking/examples/chatmem
file content:
Expected Behavior
expect smooth add_resource
Actual Behavior
failed with:
/Users/xx/code/OpenViking/.worktrees/feature/time-and-add-resource-commands/examples/chat
mem/data/viking/temp/368002f6/2026-02-03-chatmem-implementation/In-memory_history_In_ChatREPL_No
ChatSession_class-uses_OpenViking_Session_API_In_ChatREPL__init_In_run_Recording_messages_On
exit_1_Copy_your_config_2_Start_using_chatmem_3_Your_data_is_symlinked_so_RAG_data_is_shared_Sta
rts_fresh_no_session_loading_Done_-_dont_need_to_remember_this_Day_1.md: file name too long
💡 Some content may still be searchable.
Minimal Reproducible Example
Error Logs
OpenViking Version
0.1.10
Python Version
3.10
Operating System
macOS
Model Backend
None
Additional Context
No response