Skip to main content
Glama
renef-mcp
by Ahmeth4n

renef_rpc

Evaluate a Lua expression in the target process and return its result as structured JSON, including exact Lua error messages on failure.

Instructions

Evaluate a Lua expression in the target process and return its structured JSON value.

Uses Renef v0.4.0's rpc command: Lua tables become JSON arrays/objects, booleans stay true/false, and errors return exact Lua error messages.

Examples: - OS.getpid() -> 12345 - {pid = OS.getpid(), tid = Thread.id()} -> {"pid": 12345, "tid": 12360} - Module.find("libc.so") -> base address integer

Args: expression: Lua expression to evaluate timeout: Silence timeout in seconds (default: 30.0)

Returns: JSON object with ok and value

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "expression": "<expression>"
    },
    "name": "renef_rpc"
  }
}

Input Schema

NameRequiredDescriptionDefault
timeoutNo
expressionYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.0

TDQS

B3/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are supplied, so the description carries the full behavioral burden. It does disclose useful traits — Lua tables become JSON arrays/objects, booleans persist, errors surface as exact Lua error messages — but for arbitrary code execution in a live process it omits critical facts: whether evaluated code can mutate process state, whether the environment persists between calls, what happens when the 'silence timeout' elapses, and whether an attached session is required.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Well organized and front-loaded: one summary sentence, a formatting-semantics sentence, three compact examples, then Args/Returns. The examples earn their space by showing conversion behavior. Minor waste is the Returns line, which duplicates the existing output schema.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so the Returns section is a bonus rather than a necessity. For a code-evaluation tool with zero annotations that runs inside a live target process, though, the definition leaves out prerequisites (attach state), side-effect/state-persistence semantics, and timeout-expiry behavior — things an agent needs before calling it safely.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% on two parameters, so the description must compensate. It only restates 'expression: Lua expression to evaluate' and 'timeout: Silence timeout in seconds (default: 30.0)', and the key term 'silence timeout' is left undefined — it is unclear whether it bounds total execution or idleness, nor what the tool does on expiry.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: 'Evaluate a Lua expression in the target process and return its structured JSON value.' That is meaningfully more precise than the bare name renef_rpc, but it never distinguishes itself from likely siblings such as renef_exec, renef_command or renef_load_script, so an agent must guess which of those to reach for.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is implied by the examples (get a PID, build a table, resolve a module base) and the 'target process' framing shows it requires an attached process. However, there is no explicit when-to-use/when-not statement and no mention of which sibling to prefer for running scripts, shell commands, or calling native functions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.