HaroldPetersInskipp / node-red-contrib-chatgpt

A Node-RED node that interacts with OpenAI machine learning models to generate text and image outputs like 'ChatGPT' and 'DALL·E 2'.
https://flows.nodered.org/node/node-red-contrib-custom-chatgpt
MIT License
41 stars 20 forks source link

Add priming #10

Open wuast94 opened 1 year ago

wuast94 commented 1 year ago

Add Role system as configuration to enable priming

HaroldPetersInskipp commented 11 months ago

I would like to implement the "roles" feature in the node but I currently am unsure how I would like to set it up. It's my understanding that only certain models can utilize this feature, so I will have to come up with a solution that doesn't break existing configurations. I am open to suggestions if anyone has advice.

Tableautin commented 8 months ago

Is there anything new to this topic? As far as I understand the API documentation (at least for ChatGPT), the role is always optional. So if it is not set, you can always set the role to an empty string. So it should not break any existing configurations. If another model does not support this property, it should ignore it.

For priming, especially the "system" role would be great. So the answers can be tailored to work in the specific environment and with specific speech pattern (in my case, the AI should alsways behave as a good friend with friendly but slightly sarcastic answers.

I have no experience in AI development, but maybe I can help a little bit with the conceptual problems you are facing.