Skip to content

horosin/openai-functions-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OpenAI Function Calling Demo

This project demonstrates the use of OpenAI's GPT-3.5-turbo model to create a simple chat interface where the assistant can make function calls. This functionality is showcased by asking GPT-3.5-turbo for the current weather in a given location, which results in a function call to a mock weather API.

GitHub Pages demo

Demo

You can interact with the model by typing in a message and sending it. The assistant will respond accordingly. Try asking "What's the weather like in some city?"

Please note that the weather API used in this demo is a mock and always returns the same weather data.

How to Run

  1. Download or clone this repository.
  2. Open index.html in your browser.

Precautions

Please be cautious with your OpenAI API key! Do not share it or publish it online.

More Information

For more information on function calling in OpenAI's API, refer to this OpenAI blog post.

Author

This project was created by @horosin_.

Author's blog https://horosin.com.

About

Simple demo of new OpenAI Function Calling

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published