Lemma.Mcp (lemma_engine v0.9.7)

Copy Markdown View Source

Pure Lemma MCP tools: engine + arguments in, catalog or text out.

Summary

Types

args()

@type args() :: map()

engine()

@type engine() :: Lemma.engine()

Functions

check(args)

@spec check(args()) ::
  {:ok, String.t()}
  | {:error, :invalid_arguments | :not_found | :diagnostics, String.t()}

evaluate(engine, args)

@spec evaluate(engine(), args()) ::
  {:ok, String.t()}
  | {:error, :invalid_arguments | :not_found | :diagnostics, String.t()}

guide(args)

@spec guide(args()) ::
  {:ok, String.t()}
  | {:error, :invalid_arguments | :not_found | :diagnostics, String.t()}

list(engine, args)

@spec list(engine(), args()) ::
  {:ok, String.t()}
  | {:error, :invalid_arguments | :not_found | :diagnostics, String.t()}

list_resources()

@spec list_resources() :: {:ok, [map()]} | {:error, term()}

list_tools()

@spec list_tools() :: {:ok, [map()]} | {:error, term()}

read_resource(uri)

@spec read_resource(String.t()) ::
  {:ok, String.t()} | {:error, :unknown_uri, String.t()}

show(engine, args)

@spec show(engine(), args()) ::
  {:ok, String.t()}
  | {:error, :invalid_arguments | :not_found | :diagnostics, String.t()}

source(engine, args)

@spec source(engine(), args()) ::
  {:ok, String.t()}
  | {:error, :invalid_arguments | :not_found | :diagnostics, String.t()}