"""Ports only; concrete intake, embedding and publication arrive in later phases.""" from typing import Mapping, Protocol, Sequence from uuid import UUID from .types import EmbeddingProfile class FileStore(Protocol): def put(self, content: bytes) -> str: """Create a new immutable original under a generated key; never overwrite.""" ... def read(self, storage_key: str) -> bytes: ... class EmbeddingProvider(Protocol): @property def profile(self) -> EmbeddingProfile: ... def embed(self, texts: Sequence[str]) -> Sequence[Sequence[float]]: ... class DocumentRepository(Protocol): def get_document( self, organization_id: UUID, document_id: UUID ) -> Mapping[str, object] | None: ... def get_enabled_administrator(self, user_id: UUID) -> Mapping[str, object] | None: """Resolve scope from a trusted operator's persisted administrator identity.""" ...