Git Product home page Git Product logo

soenkegissel / node-red-contrib-chatgpt4o Goto Github PK

View Code? Open in Web Editor NEW

This project forked from haroldpetersinskipp/node-red-contrib-chatgpt

0.0 0.0 0.0 3.57 MB

A Node-RED node that interacts with OpenAI machine learning models to generate text and image outputs like 'ChatGPT' and 'DALL·E 2'.

Home Page: https://flows.nodered.org/node/node-red-contrib-custom-chatgpt

License: MIT License

JavaScript 57.82% HTML 42.18%

node-red-contrib-chatgpt4o's Introduction

node-red-contrib-custom-chatgpt4o

Platform npm Downloads MIT License

Supercharge your Node-RED flows with AI! Seamlessly integrate with OpenAI's powerful models like GPT-4, GPT-4o and DALL·E 2, and unlock a world of creative possibilities. Create imaginative chatbots, automate content generation, or build AI-driven experiences. The power of AI is just a node away!

Table of Contents

Getting Started

To start using node-red-contrib-custom-chatgpt4o, you can install it through the built-in Node-RED Palette manager or using npm:

npm install node-red-contrib-custom-chatgpt4o

Setup

With these, you're ready to configure your node-red-contrib-custom-chatgpt4o nodes.

Usage

With node-red-contrib-custom-chatgpt4o, you have the power to select the behavior of the node by setting the Topic property value to image, edit, turbo , or gpt4 / gpt4o. You can control the node with a single required message property msg.payload or dynamically set the behavior with incoming messages using read from msg.topic.

For detailed information on the usage of these modes, please refer to the OpenAI API documentation.

1. When msg.topic is set to completion:

  • [Required] msg.payload should be a well-written prompt that provides enough information for the model to know what you want and how it should respond. Its success generally depends on the complexity of the task and quality of your prompt. A good rule of thumb is to think about how you would write a word problem for a middle schooler to solve.
  1. When msg.topic is set to image:

    • [Required] msg.payload should be a prompt of text description of the desired image.

    • [Optional] msg.size should be a string of the desired image dimensions. [Default:256x256]

    • [Optional] msg.format should be a string of either b64_json or url. [Default:b64_json]

  2. When msg.topic is set to edit:

    • [Required] msg.payload should be a prompt of text to use as a starting point for the edit.

    • [Required] msg.last should be a string of text to use as the input to be edited.

  3. When msg.topic is set to turbo:

    • [Required] msg.payload should be a well-written prompt that provides enough information for the model to know what you want and how it should respond. Its success generally depends on the complexity of the task and quality of your prompt.

    • [Optional] msg.history should be an array of objects containing the conversation history. [Default:[]]

  4. When msg.topic is set to gpt4 or gpt4o:

    • [Required] msg.payload should be a well-written prompt that provides enough information for the model to know what you want and how it should respond. Its success generally depends on the complexity of the task and quality of your prompt.

    • [Optional] msg.history should be an array of objects containing the conversation history. [Default:[]]

Additional optional properties

The following optional inputs are supported - msg.max_tokens, msg.suffix, msg.n, msg.temperature, msg.top_p, msg.presence_penalty, msg.frequency_penalty, msg.echo, msg.API_KEY and msg.ORGANIZATION. See the nodes built-in help tab for more information on how they are used.

External Links

Bugs and Feature Requests

Encountered a bug or have an idea for a new feature? We'd love to hear from you! Feel free to submit an issue on our GitHub page.

License

This project is licensed under the MIT License - see the LICENSE file for details.

node-red-contrib-chatgpt4o's People

Contributors

haroldpetersinskipp avatar soenkegissel avatar h-takauma avatar rdshoep avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.