plexus-engine 0.3.6

Engine integration traits for consuming Plexus plans
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Feature: embedded GraphRAG sprint 2 profile

@vector @embedded-graphrag @iridium-consumer
Scenario: canonical embedded GraphRAG vector-first plan
Given a fixture graph
When executing plan mlir:
"""
func.func @embedded_graphrag_vector_first() {
  %0 = plexus.const_row : !plexus.rows<0>
  %1 = plexus.vector_scan %0 {collection = "docs", query_vector = #plexus.list<[#plexus.lit<1.0 : f64>, #plexus.lit<0.0 : f64>]>, metric = #plexus.vector_metric<dot_product>, top_k = 8 : i32, approx_hint = false, schema = [#plexus.col<"doc", node>, #plexus.col<"score", float64, "float64">]} : (!plexus.rows<0>) -> !plexus.rows<2>
  %2 = plexus.rerank %1 {score_expr = #plexus.vector_similarity<dot_product, #plexus.prop<0, "embedding">, #plexus.list<[#plexus.lit<1.0 : f64>, #plexus.lit<0.0 : f64>]>>, top_k = 4 : i32, schema = [#plexus.col<"doc", node>, #plexus.col<"score", float64, "float64">]} : (!plexus.rows<2>) -> !plexus.rows<2>
  %3 = plexus.limit %2 {count = 2 : i64, skip = 0 : i64} : (!plexus.rows<2>) -> !plexus.rows<2>
  plexus.return %3 : (!plexus.rows<2>) -> ()
}
"""
Then the result should be, in order:
  | node:1 | float:1.0 |
  | node:3 | float:0.8 |