Spaces:
Runtime error
Runtime error
Jankidepala
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -24,62 +24,62 @@ Your answer: <your answer here>"""
|
|
24 |
|
25 |
messages.append({"role": "user", "content": prompt_final})
|
26 |
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
css = """
|
56 |
-
<style>
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
</style>
|
71 |
-
"""
|
72 |
-
|
73 |
-
|
74 |
-
description = (
|
75 |
-
|
76 |
-
|
77 |
-
<div class="centered-content">
|
78 |
-
|
79 |
-
|
80 |
-
</div>
|
81 |
-
"""
|
82 |
-
)
|
83 |
|
84 |
|
85 |
|
|
|
24 |
|
25 |
messages.append({"role": "user", "content": prompt_final})
|
26 |
|
27 |
+
# client = OpenAI(api_key="sk-proj-U4WDruCnBYaUFJHaStvAT3BlbkFJ8buf9OOPTbFmmuGomSqN", base_url="http://semikong.aitomatic.com:8081/v1")
|
28 |
+
# response = client.chat.completions.create(
|
29 |
+
# model=MODEL,
|
30 |
+
# messages=messages,
|
31 |
+
# # stream=True,
|
32 |
+
# max_tokens=1024,
|
33 |
+
# temperature=0.0,
|
34 |
+
# n=1,
|
35 |
+
# presence_penalty=0.7,
|
36 |
+
# top_p=1.0,
|
37 |
+
# extra_body={
|
38 |
+
# "frequency_penalty": 0.5,
|
39 |
+
# "repetition_penalty": 1.0,
|
40 |
+
# "length_penalty": 1.0,
|
41 |
+
# "top_k": 50,
|
42 |
+
# "min_p": 0.8,
|
43 |
+
# "best_of": 1,
|
44 |
+
# "use_beam_search": False,
|
45 |
+
# "early_stopping": False,
|
46 |
+
# },
|
47 |
+
# )
|
48 |
+
|
49 |
+
# # Extract the answer from the response
|
50 |
+
# answer = response.choices[0].message.content
|
51 |
+
|
52 |
+
# # Return the answer
|
53 |
+
# return answer
|
54 |
+
|
55 |
+
# css = """
|
56 |
+
# <style>
|
57 |
+
# .centered-content {
|
58 |
+
# text-align: center;
|
59 |
+
# margin: auto;
|
60 |
+
# max-width: 800px;
|
61 |
+
# }
|
62 |
+
# .centered-content h2 {
|
63 |
+
# color: #333;
|
64 |
+
# margin-bottom: 20px;
|
65 |
+
# }
|
66 |
+
# .centered-content p {
|
67 |
+
# color: #666;
|
68 |
+
# line-height: 1.6;
|
69 |
+
# }
|
70 |
+
# </style>
|
71 |
+
# """
|
72 |
+
|
73 |
+
|
74 |
+
# description = (
|
75 |
+
# css
|
76 |
+
# + """
|
77 |
+
# <div class="centered-content">
|
78 |
+
# <h2>The world's first open-source LLM designed specifically for the semiconductor industry.</h2>
|
79 |
+
# <p>SemiKong is a collaborative open-source effort with support from Aitomatic, TEL, FPT AI Center, The AI Alliance</p>
|
80 |
+
# </div>
|
81 |
+
# """
|
82 |
+
# )
|
83 |
|
84 |
|
85 |
|