Hi, I’ve successfully set up a custom custom GPT model with a custom action to retrieve information from an external API, which works fairly well, though it has occasional issues (but that’s a separate matter).
I’m now attempting to create a similar assistant in the OpenAI Playground to be used via API, but I’m struggling to configure a custom action in the same manner as I did with ChatGPT. When I try to replicate the JSON configuration from the custom actions in my GPT-3 model, I get an “Invalid JSON” error.
I’ve loaded an example JSON of actions in the Playground, but it’s not clear how to set up the external API call.
Additionally, I’m looking to build an assistant that fetches a product list from my API and makes recommendations to the user based on that list.
ChatGPT has an authentication method similar to plugins to access your API site on your given domain, not to randomly hit other party’s APIs for profit.
When using the OpenAI API to use models, you would use function call (now tools) to specify a particular function (such as do_trigonometry), and then you would receive a function call from the AI when obtaining the status of a run.
Then in your own code, you would calculate when the AI wants to know sin(3/17), or you would send that to the other mathematics API site that you subscribe to. Then return the result to the assistant so that it can answer the user (which is giving the result back to your code but in language model answer form).