Resource extension that synthesizes :eval and :docs generic actions for
driving an LLM agent against a scoped Lua surface.
defmodule MyApp.Agents.MCPActions do
use Ash.Resource, extensions: [AshLua.EvalActions]
eval_actions do
labels [:public]
end
endThe synthesized actions inherit the caller's actor / tenant / context. Both the script body and the documentation rendering are constrained to the configured action labels, and every Ash call inside the Lua script flows through the standard authorization machinery.