
Loading...

Loading...
Capability ยท Inference
Send an encrypted prompt and get a verifiable answer back - signed and paid by your own connected wallet, the exact flow any dApp runs. Switch network from the toggle in the top bar.
import { runInferenceWithKey } from "lightnode-sdk";
const { answer, txs } = await runInferenceWithKey({
network: "mainnet",
privateKey: process.env.PRIVATE_KEY, // 0x... funded key
prompt: "Reply with a one-sentence fun fact about the ocean.",
});
console.log(answer); // the decrypted reply
console.log(txs.submitJob); // verifiable on-chain receiptSame five-line call any dApp uses. Drop it into a project with npx lightnode add inference.