MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / graph_pagerank_impl

Method graph_pagerank_impl

nodedb-client/src/remote/client/graph.rs:159–174  ·  view source on GitHub ↗
(
        &self,
        collection: &str,
        personalization: Option<&std::collections::HashMap<String, f64>>,
        damping: Option<f64>,
        max_iterations: Option<u32>,
    )

Source from the content-addressed store, hash-verified

157 }
158
159 pub(super) async fn graph_pagerank_impl(
160 &self,
161 collection: &str,
162 personalization: Option<&std::collections::HashMap<String, f64>>,
163 damping: Option<f64>,
164 max_iterations: Option<u32>,
165 ) -> NodeDbResult<Vec<(String, f64)>> {
166 let sql = crate::graph_dsl::build_pagerank_sql(
167 collection,
168 personalization,
169 damping,
170 max_iterations,
171 )?;
172 let (columns, rows) = self.simple_query_raw(&sql).await?;
173 crate::graph_dsl::parse_pagerank_rows(&columns, &rows)
174 }
175
176 pub(super) async fn graph_shortest_path_impl(
177 &self,

Callers 1

graph_pagerankMethod · 0.45

Calls 3

build_pagerank_sqlFunction · 0.85
parse_pagerank_rowsFunction · 0.85
simple_query_rawMethod · 0.80

Tested by

no test coverage detected