namespace TeamUp.SharedKernel.Ai; public enum MemoryKind { Decision, Approval, Correction, } public sealed record MemoryHit(Guid Id, MemoryKind Kind, string Content, DateTimeOffset CreatedAtUtc); /// /// Team-scoped working memory: written when a human approves (or corrects) agent work, read at /// prompt assembly via pgvector similarity. Implemented by the Memory module. Strictly isolated /// per team — institutional knowledge is the moat. /// public interface ITeamMemory { Task WriteAsync( Guid teamId, MemoryKind kind, string content, Guid? sourceReviewItemId = null, CancellationToken cancellationToken = default); Task> SearchAsync( Guid teamId, string query, int take = 3, CancellationToken cancellationToken = default); }