SDK·GitHub·Other
OpenAI Agents SDK — Prediction Market Tools
Function-calling tools for OpenAI Agents SDK and Chat Completions
Install
npm i @spfunctions/openai-agents-prediction-marketsJSON-schema function-calling tools you can drop into any OpenAI agent. The tools resolve to SimpleFunctions API calls under the hood.
Works with both the official openai Python library and the newer OpenAI Agents SDK. Tool descriptions are tuned for GPT-4o to know when to use what.
Quickstart
import { makeTools } from '@spfunctions/openai-agents-prediction-markets'
import OpenAI from 'openai'
const tools = makeTools({ apiKey: process.env.SF_API_KEY })
const openai = new OpenAI()
const res = await openai.chat.completions.create({
model: 'gpt-4o',
messages,
tools,
})
Tags
openaisdkagenttypescripttoolfunction-calling