mirror of
https://github.com/memohai/Memoh.git
synced 2026-04-27 07:16:19 +09:00
ca5c6a1866
- Rename chat module to conversation with flow-based architecture - Move channelidentities into channel/identities subpackage - Add channel/route for routing logic - Add message service with event hub - Add MCP providers: container, directory, schedule - Refactor Feishu/Telegram adapters with directory and stream support - Add platform management page and channel badges in web UI - Update database schema for conversations, messages and channel routes - Add @memoh/shared package for cross-package type definitions
21 lines
603 B
Go
21 lines
603 B
Go
package conversation
|
|
|
|
import "context"
|
|
|
|
// Reader defines conversation lookup behavior.
|
|
type Reader interface {
|
|
Get(ctx context.Context, conversationID string) (Chat, error)
|
|
}
|
|
|
|
// ParticipantChecker defines participant membership checks.
|
|
type ParticipantChecker interface {
|
|
IsParticipant(ctx context.Context, conversationID, channelIdentityID string) (bool, error)
|
|
}
|
|
|
|
// Accessor defines read access checks for conversation-scoped operations.
|
|
type Accessor interface {
|
|
Reader
|
|
ParticipantChecker
|
|
GetReadAccess(ctx context.Context, conversationID, channelIdentityID string) (ChatReadAccess, error)
|
|
}
|