pub struct GraphRAGFunctions { /* private fields */ }Expand description
GraphRAG SPARQL function definitions
These functions extend SPARQL with GraphRAG capabilities:
- graphrag:query(text) - Execute GraphRAG query
- graphrag:similar(entity, threshold) - Find similar entities
- graphrag:expand(entity, hops) - Expand from entity
- graphrag:community(graph) - Detect communities
Implementations§
Source§impl GraphRAGFunctions
impl GraphRAGFunctions
Sourcepub fn get(&self, name: &str) -> Option<&FunctionDef>
pub fn get(&self, name: &str) -> Option<&FunctionDef>
Get function definition by name
Sourcepub fn all(&self) -> impl Iterator<Item = &FunctionDef>
pub fn all(&self) -> impl Iterator<Item = &FunctionDef>
Get all function definitions
Sourcepub fn generate_service_clause(
&self,
function: &str,
args: &[&str],
) -> GraphRAGResult<String>
pub fn generate_service_clause( &self, function: &str, args: &[&str], ) -> GraphRAGResult<String>
Generate SPARQL SERVICE clause for GraphRAG
Sourcepub fn parse_query(&self, sparql: &str) -> Vec<FunctionCall>
pub fn parse_query(&self, sparql: &str) -> Vec<FunctionCall>
Parse SPARQL query for GraphRAG function calls
Trait Implementations§
Source§impl Clone for GraphRAGFunctions
impl Clone for GraphRAGFunctions
Source§fn clone(&self) -> GraphRAGFunctions
fn clone(&self) -> GraphRAGFunctions
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for GraphRAGFunctions
impl Debug for GraphRAGFunctions
Auto Trait Implementations§
impl Freeze for GraphRAGFunctions
impl RefUnwindSafe for GraphRAGFunctions
impl Send for GraphRAGFunctions
impl Sync for GraphRAGFunctions
impl Unpin for GraphRAGFunctions
impl UnwindSafe for GraphRAGFunctions
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
Mutably borrows from an owned value. Read more