Browse Source

AI rule node: change default prompts

pull/13371/head
Dmytro Skarzhynets 1 year ago
parent
commit
b64b5795a3
No known key found for this signature in database GPG Key ID: 2B51652F224037DF
  1. 9
      rule-engine/rule-engine-components/src/main/java/org/thingsboard/rule/engine/ai/TbAiNodeConfiguration.java

9
rule-engine/rule-engine-components/src/main/java/org/thingsboard/rule/engine/ai/TbAiNodeConfiguration.java

@ -49,13 +49,8 @@ public class TbAiNodeConfiguration implements NodeConfiguration<TbAiNodeConfigur
@Override @Override
public TbAiNodeConfiguration defaultConfiguration() { public TbAiNodeConfiguration defaultConfiguration() {
var configuration = new TbAiNodeConfiguration(); var configuration = new TbAiNodeConfiguration();
configuration.setSystemPrompt(""" configuration.setSystemPrompt("You are helpful assistant. Your response must be in JSON format.");
Take a deep breath and work on this step by step. configuration.setUserPrompt("Tell me a joke.");
You are an industry-leading IoT domain expert with deep experience in telemetry data analysis.
Your task is to complete the user-provided task or answer a question.
You may use additional context information called "Rule engine message payload", "Rule engine message metadata" and "Rule engine message type".
Your response must be in JSON format.""");
configuration.setUserPrompt("Tell me a joke");
return configuration; return configuration;
} }

Loading…
Cancel
Save