LLM Inference
Methods
inferString
function inferString(string prompt, string system, bool chainOfThought, string[] allowedValues) returns (string response)Parameters
Input
Type
Description
Returns
Output
Type
Description
inferNumber
function inferNumber(string prompt, string system, int256 minValue, int256 maxValue, bool chainOfThought) returns (int256 response)Parameters
Input
Type
Description
Returns
Output
Type
Description
inferChat
Parameters
Input
Type
Description
Returns
Output
Type
Description
inferToolsChat
Tool Definitions
Parameters
Input
Type
Description
Returns
Output
Type
Description
Return Semantics
Tool Use Flow
MCP Tools (Automatic)
On-Chain Tools (Yield & Resume)
Resuming After On-Chain Tool Calls
Deterministic Execution
Example Use Cases
Usage Examples
Simple Inference
Numeric Inference
Conversational Example
MCP Tool Use (Solidity)
On-Chain Tool Use with Yield & Resume (Solidity)
Last updated