mirror of
https://github.com/1Panel-dev/MaxKB.git
synced 2025-12-26 01:33:05 +00:00
chore: update negative prompt handling and fix tooltip field labels
This commit is contained in:
parent
83456553f2
commit
15af6c97f8
|
|
@ -35,7 +35,7 @@ class BaseImageGenerateNode(IImageGenerateNode):
|
|||
message_list = self.generate_message_list(question, history_message)
|
||||
self.context['message_list'] = message_list
|
||||
self.context['dialogue_type'] = dialogue_type
|
||||
self.context['negative_prompt'] = negative_prompt
|
||||
self.context['negative_prompt'] = self.generate_prompt_question(negative_prompt)
|
||||
image_urls = tti_model.generate_image(question, negative_prompt)
|
||||
# 保存图片
|
||||
file_urls = []
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ class BaseImageToVideoNode(IImageToVideoNode):
|
|||
message_list = self.generate_message_list(question, history_message)
|
||||
self.context['message_list'] = message_list
|
||||
self.context['dialogue_type'] = dialogue_type
|
||||
self.context['negative_prompt'] = negative_prompt
|
||||
self.context['negative_prompt'] = self.generate_prompt_question(negative_prompt)
|
||||
self.context['first_frame_url'] = first_frame_url
|
||||
self.context['last_frame_url'] = last_frame_url
|
||||
# 处理首尾帧图片 这块可以是url 也可以是file_id 如果是url 可以直接传递给模型 如果是file_id 需要传base64
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ class BaseTextToVideoNode(ITextToVideoNode):
|
|||
message_list = self.generate_message_list(question, history_message)
|
||||
self.context['message_list'] = message_list
|
||||
self.context['dialogue_type'] = dialogue_type
|
||||
self.context['negative_prompt'] = negative_prompt
|
||||
self.context['negative_prompt'] = self.generate_prompt_question(negative_prompt)
|
||||
video_urls = ttv_model.generate_video(question, negative_prompt)
|
||||
print('video_urls', video_urls)
|
||||
# 保存图片
|
||||
|
|
|
|||
|
|
@ -15,17 +15,17 @@ class SiliconCloudTTSModelGeneralParams(BaseForm):
|
|||
TooltipLabel('Voice',
|
||||
_('Try out the different sounds (Alloy, Echo, Fable, Onyx, Nova, and Sparkle) to find one that suits your desired tone and audience. The current voiceover is optimized for English.')),
|
||||
required=True, default_value='fnlp/MOSS-TTSD-v0.5:alex',
|
||||
text_field='value',
|
||||
text_field='label',
|
||||
value_field='value',
|
||||
option_list=[
|
||||
{'text': 'alex', 'value': 'fnlp/MOSS-TTSD-v0.5:alex'},
|
||||
{'text': 'anna', 'value': 'fnlp/MOSS-TTSD-v0.5:anna'},
|
||||
{'text': 'bella', 'value': 'fnlp/MOSS-TTSD-v0.5:bella'},
|
||||
{'text': 'charles', 'value': 'fnlp/MOSS-TTSD-v0.5:charles'},
|
||||
{'text': 'benjamin', 'value': 'fnlp/MOSS-TTSD-v0.5:benjamin'},
|
||||
{'text': 'claire', 'value': 'fnlp/MOSS-TTSD-v0.5:claire'},
|
||||
{'text': 'david', 'value': 'fnlp/MOSS-TTSD-v0.5:david'},
|
||||
{'text': 'diana', 'value': 'fnlp/MOSS-TTSD-v0.5:diana'},
|
||||
{'label': 'alex', 'value': 'fnlp/MOSS-TTSD-v0.5:alex'},
|
||||
{'label': 'anna', 'value': 'fnlp/MOSS-TTSD-v0.5:anna'},
|
||||
{'label': 'bella', 'value': 'fnlp/MOSS-TTSD-v0.5:bella'},
|
||||
{'label': 'charles', 'value': 'fnlp/MOSS-TTSD-v0.5:charles'},
|
||||
{'label': 'benjamin', 'value': 'fnlp/MOSS-TTSD-v0.5:benjamin'},
|
||||
{'label': 'claire', 'value': 'fnlp/MOSS-TTSD-v0.5:claire'},
|
||||
{'label': 'david', 'value': 'fnlp/MOSS-TTSD-v0.5:david'},
|
||||
{'label': 'diana', 'value': 'fnlp/MOSS-TTSD-v0.5:diana'},
|
||||
])
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue