Akjava commited on
Commit
4c638ee
Β·
verified Β·
1 Parent(s): 70ba2c5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -9,7 +9,7 @@ import gradio as gr
9
 
10
  text_generator = None
11
  is_hugging_face = True
12
- model_id = "google/gemma-2-9b-it"# too big
13
  #model_id = "google/gemma-2-2b-it"
14
  huggingface_token = os.getenv("HUGGINGFACE_TOKEN")
15
  device = "auto" # torch.device("cuda" if torch.cuda.is_available() else "cpu")
@@ -56,7 +56,7 @@ if not is_hugging_face:
56
 
57
  print("initialized")
58
 
59
- #@spaces.GPU(duration=60)
60
  def generate_text(messages):
61
  if is_hugging_face:#need everytime initialize for ZeroGPU
62
  model = AutoModelForCausalLM.from_pretrained(
 
9
 
10
  text_generator = None
11
  is_hugging_face = True
12
+ model_id = "AXCXEPT/EZO-Common-9B-gemma-2-it"# too big
13
  #model_id = "google/gemma-2-2b-it"
14
  huggingface_token = os.getenv("HUGGINGFACE_TOKEN")
15
  device = "auto" # torch.device("cuda" if torch.cuda.is_available() else "cpu")
 
56
 
57
  print("initialized")
58
 
59
+ @spaces.GPU(duration=60)
60
  def generate_text(messages):
61
  if is_hugging_face:#need everytime initialize for ZeroGPU
62
  model = AutoModelForCausalLM.from_pretrained(