diff --git a/web/src/views/prompt/components/PromptCreator.vue b/web/src/views/prompt/components/PromptCreator.vue index 4877a77b..9f4ac241 100644 --- a/web/src/views/prompt/components/PromptCreator.vue +++ b/web/src/views/prompt/components/PromptCreator.vue @@ -50,7 +50,8 @@ const formValue = ref({ role: '', characteristics: [], requirements: [], - process: [] + process: [], + definitions: [], }) const rules = { @@ -117,13 +118,14 @@ const generateCharacteristics = () => { } const generateDefinition = () => { - if (formValue.value.length > 0) { + if (formValue.value.definitions.length > 0) { let xml = '' xml += ' \n' formValue.value.definitions.forEach(def => { xml += ` \n ${def.key}\n ${def.value}\n \n` }) xml += ' \n' + return xml } else { return '' }