Spaces:
Runtime error
Runtime error
set cache to false for examples
Browse files
app.py
CHANGED
@@ -18,8 +18,6 @@ This Space demonstrates the dialogue models for Nigerian Pidgin, an African lang
|
|
18 |
π For more about visit [our homepage](https://www.masakhane.io/).
|
19 |
|
20 |
"""
|
21 |
-
#π¨ Looking for an even more powerful model? Check out the large [**70B** model demo](https://huggingface.co/spaces/ysharma/Explore_llamav2_with_TGI).
|
22 |
-
#π For a smaller model that you can run on many GPUs, check our [7B model demo](https://huggingface.co/spaces/huggingface-projects/llama-2-7b-chat).
|
23 |
|
24 |
|
25 |
if not torch.cuda.is_available():
|
@@ -149,7 +147,7 @@ with gr.Blocks(css='style.css') as demo:
|
|
149 |
inputs=textbox,
|
150 |
outputs=[textbox, chatbot],
|
151 |
fn=process_example,
|
152 |
-
cache_examples=
|
153 |
)
|
154 |
|
155 |
#gr.Markdown(LICENSE)
|
|
|
18 |
π For more about visit [our homepage](https://www.masakhane.io/).
|
19 |
|
20 |
"""
|
|
|
|
|
21 |
|
22 |
|
23 |
if not torch.cuda.is_available():
|
|
|
147 |
inputs=textbox,
|
148 |
outputs=[textbox, chatbot],
|
149 |
fn=process_example,
|
150 |
+
cache_examples=False,
|
151 |
)
|
152 |
|
153 |
#gr.Markdown(LICENSE)
|
model.py
CHANGED
@@ -55,7 +55,7 @@ def run(message: str,
|
|
55 |
inputs = tokenizer([prompt], return_tensors='pt', add_special_tokens=False)
|
56 |
|
57 |
streamer = TextIteratorStreamer(tokenizer,
|
58 |
-
timeout=60
|
59 |
skip_prompt=True,
|
60 |
skip_special_tokens=True)
|
61 |
generate_kwargs = dict(
|
|
|
55 |
inputs = tokenizer([prompt], return_tensors='pt', add_special_tokens=False)
|
56 |
|
57 |
streamer = TextIteratorStreamer(tokenizer,
|
58 |
+
timeout=60,
|
59 |
skip_prompt=True,
|
60 |
skip_special_tokens=True)
|
61 |
generate_kwargs = dict(
|