chatgpt-api的node client
https://github.com/transitive-bullshit/chatgpt-api
import { ChatGPTAPI } from 'chatgpt'
const api = new ChatGPTAPI({
apiKey: process.env.OPENAI_API_KEY
})
const res = await api.sendMessage('Hello World!')
console.log(res.text)
备忘
1 回复
赞