Skip to content
This repository was archived by the owner on Oct 11, 2024. It is now read-only.

3. Usage

Lucas Vilas-Bôas edited this page Apr 18, 2023 · 6 revisions

About

This plugin was developed focusing on reducing the difficult of managing REST request and JSON responses, including the serialization/deserialization of JSON content. All contents are automatically parsed into structures to use in Blueprints or C++ and you can check all of them in the category: HttpGPT.

All processes are managed by the plugin via C++ and exposed to C++ and Blueprints, so you'll don't need to worry about separating the data, just get the pre-separated content and boom! :)

Blueprints

All blueprints can be found under the category: HttpGPT

Functions

C++

Modules: HttpGPTChatModule, HttpGPTCommonModule and HttpGPTImageModule
Tasks headers: Tasks/HttpGPTChatRequest.h and Tasks/HttpGPTImageRequest.h
You can also find some helper functions in: Utils/HttpGPTHelpers.h

Tasks Versions

There are 2 versions of 2 tasks: Using Default Options and using Custom Options:

  • Tasks that uses default option will get the default values from Project Settings -> Plugins -> HttpGPT.
  • Tasks that uses custom options accepts a structure to override the default options. The constructor of the options structure will be initialized with the default options values, so you can overwrite only what you want to differ from the default one.

More information

You can find more information about the params and OpenAI APIs at OpenAI documentation: https://platform.openai.com/docs/introduction

Chat

Tasks

  1. Send Message [...]: Send a single message to the chosen model.
  2. Send Messages [...]: This task accept an array of messages, ideal for chats 'cause you'll need the section/chat history.

Notes

Some models don't support the Chat API, and if you're trying to use the Send Messages with them, only the last message content will be used as prompt. Chat is only supported for GPT3.5 and GPT4.

Image

Tasks

  1. Request Images [...]: Send a request to OpenAI DALL-E to generate images based on the given prompt.
Clone this wiki locally