From 131a5212ce7c1cdd2db9f7f4cc87a19e8ba69992 Mon Sep 17 00:00:00 2001 From: oobabooga <112222186+oobabooga@users.noreply.github.com> Date: Mon, 4 Dec 2023 15:48:34 -0800 Subject: [PATCH] UI: update context upper limit to 200000 --- modules/shared.py | 2 +- modules/training.py | 2 +- settings-template.yaml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/shared.py b/modules/shared.py index 01f6a6ee..c0899a97 100644 --- a/modules/shared.py +++ b/modules/shared.py @@ -43,7 +43,7 @@ settings = { 'seed': -1, 'truncation_length': 2048, 'truncation_length_min': 0, - 'truncation_length_max': 32768, + 'truncation_length_max': 200000, 'max_tokens_second': 0, 'custom_stopping_strings': '', 'custom_token_bans': '', diff --git a/modules/training.py b/modules/training.py index c01f27db..ca1fffb3 100644 --- a/modules/training.py +++ b/modules/training.py @@ -165,7 +165,7 @@ def create_ui(): stride_length = gr.Slider(label='Stride', minimum=0, maximum=32768, value=512, step=256, info='Used to make the evaluation faster at the cost of accuracy. 1 = slowest but most accurate. 512 is a common value.') with gr.Column(): - max_length = gr.Slider(label='max_length', minimum=0, maximum=32768, value=0, step=256, info='The context for each evaluation. If set to 0, the maximum context length for the model will be used.') + max_length = gr.Slider(label='max_length', minimum=0, maximum=shared.settings['truncation_length_max'], value=0, step=256, info='The context for each evaluation. If set to 0, the maximum context length for the model will be used.') with gr.Row(): start_current_evaluation = gr.Button("Evaluate loaded model", interactive=not mu) diff --git a/settings-template.yaml b/settings-template.yaml index 4ca84223..cb168443 100644 --- a/settings-template.yaml +++ b/settings-template.yaml @@ -13,7 +13,7 @@ seed: -1 negative_prompt: '' truncation_length: 2048 truncation_length_min: 0 -truncation_length_max: 32768 +truncation_length_max: 200000 custom_stopping_strings: '' auto_max_new_tokens: false max_tokens_second: 0