mirror of
https://github.com/oobabooga/text-generation-webui.git
synced 2024-12-23 21:18:00 +01:00
Add a preset for FlexGen
This commit is contained in:
parent
311404e258
commit
eef6fc3cbf
2
presets/FlexGen.txt
Normal file
2
presets/FlexGen.txt
Normal file
@ -0,0 +1,2 @@
|
||||
do_sample=True
|
||||
temperature=0.5
|
@ -501,7 +501,7 @@ def create_extensions_block():
|
||||
btn_extensions.click(update_extensions_parameters, [*extensions_ui_elements], [])
|
||||
|
||||
def create_settings_menus():
|
||||
generate_params = load_preset_values(settings[f'preset{suffix}'], return_dict=True)
|
||||
generate_params = load_preset_values(settings[f'preset{suffix}'] if not args.flexgen else 'FlexGen', return_dict=True)
|
||||
|
||||
with gr.Row():
|
||||
with gr.Column():
|
||||
@ -510,7 +510,7 @@ def create_settings_menus():
|
||||
create_refresh_button(model_menu, lambda : None, lambda : {"choices": get_available_models()}, "refresh-button")
|
||||
with gr.Column():
|
||||
with gr.Row():
|
||||
preset_menu = gr.Dropdown(choices=available_presets, value=settings[f'preset{suffix}'], label='Generation parameters preset')
|
||||
preset_menu = gr.Dropdown(choices=available_presets, value=settings[f'preset{suffix}'] if not args.flexgen else 'FlexGen', label='Generation parameters preset')
|
||||
create_refresh_button(preset_menu, lambda : None, lambda : {"choices": get_available_presets()}, "refresh-button")
|
||||
|
||||
with gr.Accordion("Custom generation parameters", open=False, elem_id="accordion"):
|
||||
|
Loading…
Reference in New Issue
Block a user