kopia lustrzana https://github.com/transitive-bullshit/chatgpt-api
old-agentic
rodzic
71aae3a215
commit
b0ae5bb2d5
|
@ -7,10 +7,13 @@ import { generateText } from 'ai'
|
||||||
|
|
||||||
async function main() {
|
async function main() {
|
||||||
const tavily = new TavilyClient()
|
const tavily = new TavilyClient()
|
||||||
const openai = createOpenAI({ compatibility: 'strict' })
|
const openai = createOpenAI({ compatibility: 'compatible' })
|
||||||
|
|
||||||
const result = await generateText({
|
const result = await generateText({
|
||||||
model: openai('gpt-4o-mini'),
|
model: openai('gpt-4o-mini', {
|
||||||
|
// TODO: https://github.com/transitive-bullshit/agentic/issues/702
|
||||||
|
// structuredOutputs: true
|
||||||
|
}),
|
||||||
tools: createAISDKTools(tavily),
|
tools: createAISDKTools(tavily),
|
||||||
toolChoice: 'required',
|
toolChoice: 'required',
|
||||||
temperature: 0,
|
temperature: 0,
|
||||||
|
|
Ładowanie…
Reference in New Issue