alpaca-lora
alpaca-lora copied to clipboard
Fix the IndexError in get_response
When using the get_response
function in utils/prompter.py
, we can easily get List IndexError
due to the case sensitivity of the split
method. For example, the LLaMa's output is in lowercase, but the response_split
is in uppercase.
So, I update the function with re.split
to ignore the case differences between the model's output and response_split
.