Skip to main content

SemanticEngine

Trait SemanticEngine 

Source
pub trait SemanticEngine:
    Send
    + Sync
    + 'static {
    // Required methods
    fn ingest_triples<'life0, 'async_trait>(
        &'life0 self,
        request: Request<IngestRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<IngestResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn ingest_file<'life0, 'async_trait>(
        &'life0 self,
        request: Request<IngestFileRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<IngestResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn get_neighbors<'life0, 'async_trait>(
        &'life0 self,
        request: Request<NodeRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<NeighborResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn search<'life0, 'async_trait>(
        &'life0 self,
        request: Request<SearchRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<SearchResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn resolve_id<'life0, 'async_trait>(
        &'life0 self,
        request: Request<ResolveRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<ResolveResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn get_all_triples<'life0, 'async_trait>(
        &'life0 self,
        request: Request<EmptyRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<TriplesResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn query_sparql<'life0, 'async_trait>(
        &'life0 self,
        request: Request<SparqlRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<SparqlResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn delete_namespace_data<'life0, 'async_trait>(
        &'life0 self,
        request: Request<EmptyRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<DeleteResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn hybrid_search<'life0, 'async_trait>(
        &'life0 self,
        request: Request<HybridSearchRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<SearchResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn apply_reasoning<'life0, 'async_trait>(
        &'life0 self,
        request: Request<ReasoningRequest>,
    ) -> Pin<Box<dyn Future<Output = Result<Response<ReasoningResponse>, Status>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

Generated trait containing gRPC methods that should be implemented for use with SemanticEngineServer.

Required Methods§

Source

fn ingest_triples<'life0, 'async_trait>( &'life0 self, request: Request<IngestRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<IngestResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Ingests a batch of triples

Source

fn ingest_file<'life0, 'async_trait>( &'life0 self, request: Request<IngestFileRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<IngestResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Ingests a file (CSV, Markdown)

Source

fn get_neighbors<'life0, 'async_trait>( &'life0 self, request: Request<NodeRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<NeighborResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Queries the graph (Basic traversal for now)

Source

fn search<'life0, 'async_trait>( &'life0 self, request: Request<SearchRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<SearchResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Vector Search (Placeholder for hybrid query)

Source

fn resolve_id<'life0, 'async_trait>( &'life0 self, request: Request<ResolveRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ResolveResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Resolves a string URI to a Node ID

Source

fn get_all_triples<'life0, 'async_trait>( &'life0 self, request: Request<EmptyRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<TriplesResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get all stored triples (for graph visualization)

Source

fn query_sparql<'life0, 'async_trait>( &'life0 self, request: Request<SparqlRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<SparqlResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Executes a SPARQL query

Source

fn delete_namespace_data<'life0, 'async_trait>( &'life0 self, request: Request<EmptyRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<DeleteResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Deletes all data associated with a namespace

Hybrid search combining vector similarity and graph traversal

Source

fn apply_reasoning<'life0, 'async_trait>( &'life0 self, request: Request<ReasoningRequest>, ) -> Pin<Box<dyn Future<Output = Result<Response<ReasoningResponse>, Status>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Applies automated reasoning to a namespace

Implementors§