Repository navigation
Closed
Labels
enhancementNew feature or requestpriority:highFix in next releasescope:coreCore engine workv0.1.0Feature bump
Description
Feature: Room-based Collaborative Memory
Problem
Uteke memories are isolated per-namespace (agent). When multiple agents collaborate (e.g., in a Discord thread), there is no way to:
- Share memory context across agents in the same discussion
- Let a new agent join mid-discussion and catch up
- Track who contributed what in a multi-agent session
- Continue a session later without losing context
Proposed Solution
Add --room flag for collaborative memory spaces. A room is a shared context identified by an external ID (e.g., Discord thread ID, meeting ID).
┌─────────────────────────────────────────────┐
│ ROOM (thread ID) │
├─────────────────────────────────────────────┤
│ CTO stores: "SurrealDB graph relevant" │
│ Zeko stores: "Qdrant health check OK" │
│ BadSector: "Risk: BSL license concern" │
│ │
│ ANY agent: uteke recall --room <id> │
│ → returns ALL contributions from room │
│ │
│ New agent joins: │
│ uteke recall --room <id> --summary │
│ → condensed room context │
└─────────────────────────────────────────────┘
CLI Design
# Agent store memory in room
uteke remember "SurrealDB graph layer relevan untuk Uteke" \
--room 1514528701109506199 \
--author cto \
--type analysis \
--tags surrealdb,uteke,graph
# Agent recall room context (full)
uteke recall --room 1514528701109506199
# Agent recall room context (summary for new joiners)
uteke recall --room 1514528701109506199 --summary
# Filter by author within room
uteke recall --room 1514528701109506199 --author cto
# List all rooms
uteke room list
# Room stats
uteke room stats 1514528701109506199Schema (Option B: New Tables)
CREATE TABLE rooms (
id TEXT PRIMARY KEY, -- room ID (e.g., Discord thread ID)
title TEXT, -- optional room title
namespace TEXT NOT NULL, -- which agent created the room
created_at TEXT NOT NULL,
updated_at TEXT NOT NULL
);
CREATE TABLE room_memories (
room_id TEXT NOT NULL REFERENCES rooms(id) ON DELETE CASCADE,
memory_id TEXT NOT NULL REFERENCES memories(id) ON DELETE CASCADE,
author TEXT NOT NULL, -- who contributed
role TEXT NOT NULL DEFAULT 'participant', -- participant | lead | observer
joined_at TEXT NOT NULL DEFAULT (datetime('now')),
PRIMARY KEY (room_id, memory_id)
);
CREATE INDEX idx_room_memories_room ON room_memories(room_id);
CREATE INDEX idx_room_memories_author ON room_memories(author);Key Behaviors
--roomon remember: Stores memory in agent namespace AND links to room (dual-write). Memory is findable via personal recall AND room recall.--authoron remember/recall: Tracks who contributed. Enables attribution and filtering.uteke recall --room <id>: Returns all memories linked to the room, sorted by time, with author attribution.uteke recall --room <id> --summary: Returns condensed room context — top-K diverse results using MMR-like selection to avoid redundancy.uteke room list: Lists all rooms the current namespace has participated in.uteke room stats <id>: Shows room metadata — participant count, memory count, last activity, authors.- Cross-namespace recall: Room recall searches across ALL namespaces that contributed to the room.
Why v0.1.0
- Requires metadata enrichment (done in v0.0.13, feat: metadata enrichment — entity, category, and structured metadata via CLI flags #251)
- Requires FTS5 hybrid search (done in v0.0.13, feat: FTS5 hybrid search with Reciprocal Rank Fusion (RRF) #250)
- Foundation for graph layer (🔗 Feature: Relationship graph layer between memories #246) — room as graph node hub
- Foundation for MCP server (🔌 Feature: MCP server for AI tool integration #248) — room-aware MCP tools
- Foundation for smart decay (⭐ Feature: Smart memory decay and importance scoring #247) — room participation as importance signal
Implementation Order within v0.1.0
1. #249 Pluggable embedding (foundation)
2. THIS ISSUE — Room-based memory
3. #246 Graph relations (enhance room with traversal)
4. #248 MCP Server (expose room + graph)
5. #247 Smart decay (room participation as signal)
6. #181 Agent recall optimization (room as trigger)
Acceptance Criteria
-
--roomand--authorCLI flags on remember/recall commands -
roomsandroom_memoriestables with schema migration (version bump) -
uteke room listcommand — lists rooms for current namespace -
uteke room stats <id>command — room metadata and participants - Room recall returns all contributions sorted by time with author attribution
- Author filtering:
uteke recall --room X --author cto -
--summaryflag returns condensed room context (top-K diverse) - JSON output includes author attribution and timestamps
- Cross-namespace recall within room context
- FTS5 + vector hybrid search scoped to room when
--roomis specified - Room memories also exist in agent personal namespace (dual-write)
- Schema migration safe for existing databases
- Tests for room CRUD, cross-namespace recall, author filtering
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestpriority:highFix in next releasescope:coreCore engine workv0.1.0Feature bump
Activity
release: v0.0.14 — version bump, CHANGELOG, docs update (#288)
feat(#286): room-based collaborative memory for multi-agent discussio…
release: v0.0.14 — version bump, CHANGELOG, docs update (#288)
feat(#286): room-based collaborative memory for multi-agent discussio…