Verify code against tests (signed certificate)
soma_verify_codeRun candidate code against tests in an isolated sandbox and receive a PASS/FAIL verdict with a signed, offline-checkable certificate, confirming code works before trusting it.
Instructions
Run candidate code against tests inside an isolated sandbox and return a PASS/FAIL verdict with a signed, offline-checkable certificate (Ed25519). Use this to independently confirm that code actually works before trusting it.
Two test shapes:
function mode (default): tests = [{"input": [arg1, arg2], "expected": value}] and provide 'entrypoint' (the function name).
stdio mode: set mode='stdio' and tests = [{"stdin": "...", "expected_stdout": "..."}]; no entrypoint needed.
Supported languages include python, javascript, typescript, go, c, cpp, java, rust, ruby, php, bash and more.
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": {
"language": "<language>",
"code": "<code>",
"tests": "<tests>"
},
"name": "soma_verify_code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | Yes | The complete source code to verify. | |
| mode | No | 'function' (default) or 'stdio'. | |
| tests | Yes | function mode: [{input:[args], expected: value}]. stdio mode: [{stdin:'...', expected_stdout:'...'}]. | |
| language | Yes | Programming language, e.g. 'python', 'javascript', 'go', 'rust'. | |
| entrypoint | No | Function name to call (required for function mode; omit for stdio mode). |