Remove softprompt support
This commit is contained in:
parent
ccb4c9f178
commit
00b94847da
7 changed files with 8 additions and 106 deletions
|
@ -55,11 +55,7 @@ def generate_chat_prompt(user_input, state, **kwargs):
|
|||
is_instruct = state['mode'] == 'instruct'
|
||||
|
||||
# Find the maximum prompt size
|
||||
chat_prompt_size = state['chat_prompt_size']
|
||||
if shared.soft_prompt:
|
||||
chat_prompt_size -= shared.soft_prompt_tensor.shape[1]
|
||||
|
||||
max_length = min(get_max_prompt_length(state), chat_prompt_size)
|
||||
max_length = min(get_max_prompt_length(state), state['chat_prompt_size'])
|
||||
all_substrings = {
|
||||
'chat': get_turn_substrings(state, instruct=False),
|
||||
'instruct': get_turn_substrings(state, instruct=True)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue