Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -12,12 +12,12 @@ theme = gr.themes.Monochrome(
|
|
12 |
)
|
13 |
|
14 |
TOKEN = os.getenv("USER_TOKEN")
|
15 |
-
|
16 |
-
|
17 |
#instruct_pipeline_12b = pipeline(model="databricks/dolly-v2-12b", torch_dtype=torch.bfloat16, trust_remote_code=True, device_map="auto")
|
18 |
|
19 |
def generate(query, temperature, top_p, top_k, max_new_tokens):
|
20 |
-
return [
|
21 |
|
22 |
|
23 |
|
|
|
12 |
)
|
13 |
|
14 |
TOKEN = os.getenv("USER_TOKEN")
|
15 |
+
instruct_pipeline_falcon = pipeline(model="tiiuae/falcon-7b-instruct", torch_dtype=torch.bfloat16, trust_remote_code=True, device_map="auto")
|
16 |
+
instruct_pipeline_llama = pipeline(model="mosesjun0h/llama-7b-hf-baize-lora-bf16", torch_dtype=torch.bfloat16, trust_remote_code=True, device_map="auto", use_auth_token=TOKEN)
|
17 |
#instruct_pipeline_12b = pipeline(model="databricks/dolly-v2-12b", torch_dtype=torch.bfloat16, trust_remote_code=True, device_map="auto")
|
18 |
|
19 |
def generate(query, temperature, top_p, top_k, max_new_tokens):
|
20 |
+
return [instruct_pipeline_falcon(query, temperature, top_p, top_k, max_new_tokens), instruct_pipeline_llama(query, temperature, top_p, top_k, max_new_tokens)]
|
21 |
|
22 |
|
23 |
|