Spaces:
Runtime error
Runtime error
add spaces
Browse files12312 unmodified lines16171819202122import gradio as grimport torchfrom transformers import AutoTokenizer, AutoModelForCausalLM12 unmodified linesdef create_prompt(instruction):PROMPT = '''Below is an instruction that describes a task.\n\nWrite a response that appropriately completes the request.\n\n### Instruction:\n{instruction}\n\n### Response:'''return PROMPT.format(instruction=instruction)def respond(message, history, system_message, max_tokens, temperature, top_p):prompt = create_prompt(message)123412 unmodified lines1718192021222324import spacesimport gradio as grimport torchfrom transformers import AutoTokenizer, AutoModelForCausalLM12 unmodified linesdef create_prompt(instruction):PROMPT = '''Below is an instruction that describes a task.\n\nWrite a response that appropriately completes the request.\n\n### Instruction:\n{instruction}\n\n### Response:'''return PROMPT.format(instruction=instruction)@spaces.GPUdef respond(message, history, system_message, max_tokens, temperature, top_p):prompt = create_prompt(message)
app.py+3-1