as-cle-bert commited on
Commit
6bf3e9d
1 Parent(s): ea0487d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +0 -2
app.py CHANGED
@@ -2,7 +2,6 @@ import gradio as gr
2
  from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline
3
  from pathlib import Path
4
  import pandas as pd
5
- import spaces
6
 
7
  model_checkpoint = "HuggingFaceTB/SmolLM-135M"
8
  model = AutoModelForCausalLM.from_pretrained(model_checkpoint)
@@ -50,7 +49,6 @@ with gr.Blocks() as demo:
50
  msg = gr.Textbox()
51
  clear = gr.ClearButton([msg, chatbot])
52
 
53
- @spaces.GPU(duration=200)
54
  def respond(message, chat_history):
55
  response = pipe(message)
56
  bot_message = response[0]["generated_text"]
 
2
  from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline
3
  from pathlib import Path
4
  import pandas as pd
 
5
 
6
  model_checkpoint = "HuggingFaceTB/SmolLM-135M"
7
  model = AutoModelForCausalLM.from_pretrained(model_checkpoint)
 
49
  msg = gr.Textbox()
50
  clear = gr.ClearButton([msg, chatbot])
51
 
 
52
  def respond(message, chat_history):
53
  response = pipe(message)
54
  bot_message = response[0]["generated_text"]