Multi-Turn Session Conversation Context #3
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What & Why
In session mode, each job is currently treated as independent. Timmy has no memory of prior exchanges within the same session. Adding conversation context means follow-ups like 'now make it shorter' work naturally.
Done looks like
Out of scope
Tasks
session_messagestable (session_id, role, content, token_count, created_at); retrieval function returns last N messages within token budget./api/session/:id/history/clearendpoint.Relevant files
artifacts/api-server/src/lib/agent.tsartifacts/api-server/src/routes/jobs.tsartifacts/api-server/src/routes/sessions.tsthe-matrix/js/session.jsthe-matrix/js/ui.jsPR created: http://143.198.27.163:3000/replit/timmy-tower/pulls/92
All conversation context pieces were already implemented (DB table, migration, getSessionHistory with token budget, context injection in the request handler, frontend clear button). The only missing piece was the
DELETE /sessions/:id/historybackend endpoint — added in this PR. It requires macaroon auth and deletes all session_messages rows for the session.