Update app.py
Browse files70 unmodified lines717273747475767778797980818270 unmodified lines "temperature": temperature, "top_p": top_p, "repetition_penalty": repetition_penalty, "max_length": 512 "max_length": 1000 }, huggingfacehub_api_token=huggingface_token )
def generate_chunked_response(model, prompt, max_tokens=500, max_chunks=5):def generate_chunked_response(model, prompt, max_tokens=1000, max_chunks=5): full_response = "" for i in range(max_chunks): chunk = model(prompt + full_response, max_new_tokens=max_tokens)app.py+2-2