CMDCTest.RAG.MockGraphBackend (cmdc_test v0.3.0)

Copy Markdown View Source

CMDCRAGArcana.Graph.Backend shape-compatible fake GraphStore backend。

默认返回 enabled graph、存在的 graph tables、稳定 counts 与 evidence,用于 GraphRAG preflight/status/search 测试。

Summary

Functions

返回 graph counts。

返回 GraphRAG evidence。

返回 graph 配置摘要。

模拟 graph tables 是否存在。

Functions

graph_counts(repo, opts \\ [])

@spec graph_counts(
  module(),
  keyword()
) :: {:ok, map()} | {:error, term()}

返回 graph counts。

graph_evidence(repo, opts \\ [])

@spec graph_evidence(
  module(),
  keyword()
) :: {:ok, map()} | {:error, term()}

返回 GraphRAG evidence。

graph_info(opts \\ [])

@spec graph_info(keyword()) :: map()

返回 graph 配置摘要。

graph_tables_present?(repo, opts \\ [])

@spec graph_tables_present?(
  module(),
  keyword()
) :: boolean() | {:ok, boolean()} | {:error, term()}

模拟 graph tables 是否存在。