Update app.py
Browse files
app.py
CHANGED
@@ -43,16 +43,6 @@ pre, code {
|
|
43 |
|
44 |
system_prompt = str(os.getenv("SYSTEM_PROMPT"))
|
45 |
|
46 |
-
secret_key = str(os.getenv("LANGFUSE_SECRET_KEY"))
|
47 |
-
public_key = str(os.getenv("LANGFUSE_PUBLIC_KEY"))
|
48 |
-
host = str(os.getenv("LANGFUSE_HOST"))
|
49 |
-
|
50 |
-
langfuse = Langfuse(
|
51 |
-
secret_key=secret_key,
|
52 |
-
public_key=public_key,
|
53 |
-
host=host
|
54 |
-
)
|
55 |
-
|
56 |
|
57 |
def execution_time_calculator(start_time, log=True):
|
58 |
delta = time.time() - start_time
|
@@ -68,7 +58,7 @@ if not torch.cuda.is_available():
|
|
68 |
|
69 |
|
70 |
if torch.cuda.is_available():
|
71 |
-
model_id = "
|
72 |
model = AutoModelForCausalLM.from_pretrained(model_id, device_map="auto", torch_dtype=torch.bfloat16)
|
73 |
tokenizer = AutoTokenizer.from_pretrained(model_id)
|
74 |
|
|
|
43 |
|
44 |
system_prompt = str(os.getenv("SYSTEM_PROMPT"))
|
45 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
46 |
|
47 |
def execution_time_calculator(start_time, log=True):
|
48 |
delta = time.time() - start_time
|
|
|
58 |
|
59 |
|
60 |
if torch.cuda.is_available():
|
61 |
+
model_id = "PartAI/Dorna-Llama3-8B-Instruct"
|
62 |
model = AutoModelForCausalLM.from_pretrained(model_id, device_map="auto", torch_dtype=torch.bfloat16)
|
63 |
tokenizer = AutoTokenizer.from_pretrained(model_id)
|
64 |
|