Add auto_max_new_tokens parameter (#3419)

This commit is contained in:
oobabooga 2023-08-02 14:52:20 -03:00 committed by GitHub
parent 0d9932815c
commit e931844fe2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 17 additions and 0 deletions

View file

@ -20,6 +20,7 @@ async def run(user_input, history):
request = {
'user_input': user_input,
'max_new_tokens': 250,
'auto_max_new_tokens': False,
'history': history,
'mode': 'instruct', # Valid options: 'chat', 'chat-instruct', 'instruct'
'character': 'Example',

View file

@ -14,6 +14,7 @@ def run(user_input, history):
request = {
'user_input': user_input,
'max_new_tokens': 250,
'auto_max_new_tokens': False,
'history': history,
'mode': 'instruct', # Valid options: 'chat', 'chat-instruct', 'instruct'
'character': 'Example',

View file

@ -20,6 +20,7 @@ async def run(context):
request = {
'prompt': context,
'max_new_tokens': 250,
'auto_max_new_tokens': False,
# Generation params. If 'preset' is set to different than 'None', the values
# in presets/preset-name.yaml are used instead of the individual numbers.

View file

@ -12,6 +12,7 @@ def run(prompt):
request = {
'prompt': prompt,
'max_new_tokens': 250,
'auto_max_new_tokens': False,
# Generation params. If 'preset' is set to different than 'None', the values
# in presets/preset-name.yaml are used instead of the individual numbers.