VeganSquirrel commited on
Commit
52c8c41
·
verified ·
1 Parent(s): 535ee0d
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -40,7 +40,7 @@ index.add(embeddings)
40
 
41
  model_name = "TheBloke/zephyr-7B-beta-GPTQ"
42
  tokenizer = AutoTokenizer.from_pretrained(model_name, use_fast=True)
43
- model = AutoModelForCausalLM.from_pretrained(model_name, device_map="auto", trust_remote_code=False)
44
 
45
 
46
  # Step 4: Define the Retrieval Function
@@ -67,7 +67,7 @@ def gradio_interface(query):
67
 
68
  iface = gr.Interface(
69
  fn=gradio_interface,
70
- inputs=gr.inputs.Textbox(lines=2, placeholder="Enter your query here..."),
71
  outputs="text",
72
  title="RAG-based Course Search",
73
  description="Enter a query to search for relevant courses using Retrieval Augmented Generation."
 
40
 
41
  model_name = "TheBloke/zephyr-7B-beta-GPTQ"
42
  tokenizer = AutoTokenizer.from_pretrained(model_name, use_fast=True)
43
+ model = AutoModelForCausalLM.from_pretrained(model_name, device_map="cpu", trust_remote_code=False, use_exllama=False))
44
 
45
 
46
  # Step 4: Define the Retrieval Function
 
67
 
68
  iface = gr.Interface(
69
  fn=gradio_interface,
70
+ inputs=gr.Textbox(lines=2, placeholder="Enter your query here..."),
71
  outputs="text",
72
  title="RAG-based Course Search",
73
  description="Enter a query to search for relevant courses using Retrieval Augmented Generation."