pub struct MemoryServiceImpl { /* private fields */ }Expand description
Canonical PostCortexService implementation backed by
ConversationMemorySystem.
Construct with Self::new passing an Arc<ConversationMemorySystem>
(typically the singleton owned by the daemon).
Implementations§
Source§impl MemoryServiceImpl
impl MemoryServiceImpl
Sourcepub fn new(system: Arc<ConversationMemorySystem>) -> Self
pub fn new(system: Arc<ConversationMemorySystem>) -> Self
Wrap an existing memory system in the canonical service trait, starting the non-blocking write pipeline with default capacities. Must be called from inside a Tokio runtime.
Sourcepub fn with_pipeline_config(
system: Arc<ConversationMemorySystem>,
config: PipelineConfig,
) -> Self
pub fn with_pipeline_config( system: Arc<ConversationMemorySystem>, config: PipelineConfig, ) -> Self
Wrap an existing memory system in the service trait with an explicit pipeline configuration.
Sourcepub fn pipeline(&self) -> &Arc<Pipeline>
pub fn pipeline(&self) -> &Arc<Pipeline>
Borrow the non-blocking pipeline. Exposed so transport adapters can submit derived-work items directly (e.g. enqueue an embedding compute after a manual storage write).
Sourcepub fn inner(&self) -> &Arc<ConversationMemorySystem>
pub fn inner(&self) -> &Arc<ConversationMemorySystem>
Borrow the underlying memory system. Provided so the daemon’s gRPC handlers can fall back to direct calls for methods that have not been migrated to the trait yet.
Trait Implementations§
Source§impl PostCortexService for MemoryServiceImpl
impl PostCortexService for MemoryServiceImpl
Source§fn health<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<HealthReport, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn health<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<HealthReport, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn update_context<'life0, 'async_trait>(
&'life0 self,
req: UpdateContextRequest,
) -> Pin<Box<dyn Future<Output = Result<UpdateContextResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn update_context<'life0, 'async_trait>(
&'life0 self,
req: UpdateContextRequest,
) -> Pin<Box<dyn Future<Output = Result<UpdateContextResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn bulk_update_context<'life0, 'async_trait>(
&'life0 self,
req: BulkUpdateContextRequest,
) -> Pin<Box<dyn Future<Output = Result<BulkUpdateContextResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn bulk_update_context<'life0, 'async_trait>(
&'life0 self,
req: BulkUpdateContextRequest,
) -> Pin<Box<dyn Future<Output = Result<BulkUpdateContextResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Self::update_context. Backends use storage
write batches when available (RocksDB transaction).Source§fn semantic_search<'life0, 'async_trait>(
&'life0 self,
_req: SemanticSearchRequest,
) -> Pin<Box<dyn Future<Output = Result<SemanticSearchResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn semantic_search<'life0, 'async_trait>(
&'life0 self,
_req: SemanticSearchRequest,
) -> Pin<Box<dyn Future<Output = Result<SemanticSearchResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn query_context<'life0, 'async_trait>(
&'life0 self,
_req: QueryContextRequest,
) -> Pin<Box<dyn Future<Output = Result<QueryContextResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn query_context<'life0, 'async_trait>(
&'life0 self,
_req: QueryContextRequest,
) -> Pin<Box<dyn Future<Output = Result<QueryContextResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn assemble_context<'life0, 'async_trait>(
&'life0 self,
_req: AssembleContextRequest,
) -> Pin<Box<dyn Future<Output = Result<AssembleContextResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn assemble_context<'life0, 'async_trait>(
&'life0 self,
_req: AssembleContextRequest,
) -> Pin<Box<dyn Future<Output = Result<AssembleContextResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn manage_session<'life0, 'async_trait>(
&'life0 self,
_req: ManageSessionRequest,
) -> Pin<Box<dyn Future<Output = Result<ManageSessionResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn manage_session<'life0, 'async_trait>(
&'life0 self,
_req: ManageSessionRequest,
) -> Pin<Box<dyn Future<Output = Result<ManageSessionResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn manage_workspace<'life0, 'async_trait>(
&'life0 self,
_req: ManageWorkspaceRequest,
) -> Pin<Box<dyn Future<Output = Result<ManageWorkspaceResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn manage_workspace<'life0, 'async_trait>(
&'life0 self,
_req: ManageWorkspaceRequest,
) -> Pin<Box<dyn Future<Output = Result<ManageWorkspaceResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Self::manage_session.Source§fn manage_entity<'life0, 'async_trait>(
&'life0 self,
_req: ManageEntityRequest,
) -> Pin<Box<dyn Future<Output = Result<ManageEntityResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn manage_entity<'life0, 'async_trait>(
&'life0 self,
_req: ManageEntityRequest,
) -> Pin<Box<dyn Future<Output = Result<ManageEntityResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn get_structured_summary<'life0, 'async_trait>(
&'life0 self,
_req: StructuredSummaryRequest,
) -> Pin<Box<dyn Future<Output = Result<StructuredSummaryResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_structured_summary<'life0, 'async_trait>(
&'life0 self,
_req: StructuredSummaryRequest,
) -> Pin<Box<dyn Future<Output = Result<StructuredSummaryResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§fn admin<'life0, 'async_trait>(
&'life0 self,
_req: AdminRequest,
) -> Pin<Box<dyn Future<Output = Result<AdminResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn admin<'life0, 'async_trait>(
&'life0 self,
_req: AdminRequest,
) -> Pin<Box<dyn Future<Output = Result<AdminResponse, SystemError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Auto Trait Implementations§
impl Freeze for MemoryServiceImpl
impl !RefUnwindSafe for MemoryServiceImpl
impl Send for MemoryServiceImpl
impl Sync for MemoryServiceImpl
impl Unpin for MemoryServiceImpl
impl UnsafeUnpin for MemoryServiceImpl
impl !UnwindSafe for MemoryServiceImpl
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::RequestSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request