Spaces:
Runtime error
Runtime error
Update chain_app.py
Browse files- chain_app.py +91 -96
chain_app.py
CHANGED
|
@@ -322,9 +322,9 @@ async def on_chat_start():
|
|
| 322 |
]
|
| 323 |
).send()
|
| 324 |
|
| 325 |
-
await cl.Message(
|
| 326 |
-
|
| 327 |
-
).send()
|
| 328 |
if chat_profile == 'gpt4-o-mini':
|
| 329 |
await cl.ChatSettings(
|
| 330 |
[
|
|
@@ -344,9 +344,9 @@ async def on_chat_start():
|
|
| 344 |
),
|
| 345 |
]
|
| 346 |
).send()
|
| 347 |
-
await cl.Message(
|
| 348 |
-
|
| 349 |
-
).send()
|
| 350 |
|
| 351 |
# if chat_profile == 'Image-Generation':
|
| 352 |
# image = cl.Image(path='cat.png', name="result", display="inline")
|
|
@@ -373,9 +373,9 @@ async def on_chat_start():
|
|
| 373 |
),
|
| 374 |
]
|
| 375 |
).send()
|
| 376 |
-
await cl.Message(
|
| 377 |
-
|
| 378 |
-
).send()
|
| 379 |
|
| 380 |
if chat_profile == 'gpt-3.5-turbo':
|
| 381 |
await cl.ChatSettings(
|
|
@@ -396,9 +396,9 @@ async def on_chat_start():
|
|
| 396 |
),
|
| 397 |
]
|
| 398 |
).send()
|
| 399 |
-
await cl.Message(
|
| 400 |
-
|
| 401 |
-
).send()
|
| 402 |
# if chat_profile == 'GPT-3.5-turbo-0125':
|
| 403 |
# await cl.ChatSettings(
|
| 404 |
# [
|
|
@@ -441,9 +441,9 @@ async def on_chat_start():
|
|
| 441 |
),
|
| 442 |
]
|
| 443 |
).send()
|
| 444 |
-
await cl.Message(
|
| 445 |
-
|
| 446 |
-
).send()
|
| 447 |
|
| 448 |
# if chat_profile == 'davinci-002':
|
| 449 |
# await cl.ChatSettings(
|
|
@@ -491,9 +491,9 @@ async def on_chat_start():
|
|
| 491 |
),
|
| 492 |
]
|
| 493 |
).send()
|
| 494 |
-
await cl.Message(
|
| 495 |
-
|
| 496 |
-
).send()
|
| 497 |
|
| 498 |
if chat_profile == 'Qwen2-7B':
|
| 499 |
await cl.ChatSettings(
|
|
@@ -514,9 +514,9 @@ async def on_chat_start():
|
|
| 514 |
),
|
| 515 |
]
|
| 516 |
).send()
|
| 517 |
-
await cl.Message(
|
| 518 |
-
|
| 519 |
-
).send()
|
| 520 |
|
| 521 |
if chat_profile == 'Qwen2-1.5B':
|
| 522 |
await cl.ChatSettings(
|
|
@@ -537,9 +537,9 @@ async def on_chat_start():
|
|
| 537 |
),
|
| 538 |
]
|
| 539 |
).send()
|
| 540 |
-
await cl.Message(
|
| 541 |
-
|
| 542 |
-
).send()
|
| 543 |
|
| 544 |
if chat_profile == 'Qwen2-0.5B':
|
| 545 |
await cl.ChatSettings(
|
|
@@ -560,9 +560,9 @@ async def on_chat_start():
|
|
| 560 |
),
|
| 561 |
]
|
| 562 |
).send()
|
| 563 |
-
await cl.Message(
|
| 564 |
-
|
| 565 |
-
).send()
|
| 566 |
|
| 567 |
if chat_profile == 'Qwen1.5-110B':
|
| 568 |
await cl.ChatSettings(
|
|
@@ -583,9 +583,9 @@ async def on_chat_start():
|
|
| 583 |
),
|
| 584 |
]
|
| 585 |
).send()
|
| 586 |
-
await cl.Message(
|
| 587 |
-
|
| 588 |
-
).send()
|
| 589 |
|
| 590 |
# if chat_profile == 'Qwen1.5-72B':
|
| 591 |
# await cl.ChatSettings(
|
|
@@ -629,9 +629,9 @@ async def on_chat_start():
|
|
| 629 |
),
|
| 630 |
]
|
| 631 |
).send()
|
| 632 |
-
await cl.Message(
|
| 633 |
-
|
| 634 |
-
).send()
|
| 635 |
|
| 636 |
if chat_profile == 'Qwen1.5-2.7B':
|
| 637 |
await cl.ChatSettings(
|
|
@@ -652,9 +652,9 @@ async def on_chat_start():
|
|
| 652 |
),
|
| 653 |
]
|
| 654 |
).send()
|
| 655 |
-
await cl.Message(
|
| 656 |
-
|
| 657 |
-
).send()
|
| 658 |
|
| 659 |
# if chat_profile == 'Qwen-72B':
|
| 660 |
# await cl.ChatSettings(
|
|
@@ -743,10 +743,10 @@ async def on_chat_start():
|
|
| 743 |
step=0.1,
|
| 744 |
),
|
| 745 |
]
|
| 746 |
-
).send()
|
| 747 |
-
await cl.Message(
|
| 748 |
-
|
| 749 |
-
).send()
|
| 750 |
|
| 751 |
if chat_profile == 'Llama-3.1-70B':
|
| 752 |
await cl.ChatSettings(
|
|
@@ -767,9 +767,9 @@ async def on_chat_start():
|
|
| 767 |
),
|
| 768 |
]
|
| 769 |
).send()
|
| 770 |
-
await cl.Message(
|
| 771 |
-
|
| 772 |
-
).send()
|
| 773 |
if chat_profile == 'Llama-3.1-8B':
|
| 774 |
await cl.ChatSettings(
|
| 775 |
[
|
|
@@ -789,9 +789,9 @@ async def on_chat_start():
|
|
| 789 |
),
|
| 790 |
]
|
| 791 |
).send()
|
| 792 |
-
await cl.Message(
|
| 793 |
-
|
| 794 |
-
).send()
|
| 795 |
|
| 796 |
if chat_profile == 'Llama-3-70B':
|
| 797 |
await cl.ChatSettings(
|
|
@@ -812,9 +812,9 @@ async def on_chat_start():
|
|
| 812 |
),
|
| 813 |
]
|
| 814 |
).send()
|
| 815 |
-
await cl.Message(
|
| 816 |
-
|
| 817 |
-
).send()
|
| 818 |
if chat_profile == 'Llama-3-8B':
|
| 819 |
await cl.ChatSettings(
|
| 820 |
[
|
|
@@ -835,9 +835,9 @@ async def on_chat_start():
|
|
| 835 |
]
|
| 836 |
).send()
|
| 837 |
|
| 838 |
-
await cl.Message(
|
| 839 |
-
|
| 840 |
-
).send()
|
| 841 |
|
| 842 |
if chat_profile == 'Aya-23B':
|
| 843 |
await cl.ChatSettings(
|
|
@@ -858,9 +858,9 @@ async def on_chat_start():
|
|
| 858 |
),
|
| 859 |
]
|
| 860 |
).send()
|
| 861 |
-
await cl.Message(
|
| 862 |
-
|
| 863 |
-
).send()
|
| 864 |
|
| 865 |
if chat_profile == 'Aya-35B':
|
| 866 |
await cl.ChatSettings(
|
|
@@ -881,9 +881,9 @@ async def on_chat_start():
|
|
| 881 |
),
|
| 882 |
]
|
| 883 |
).send()
|
| 884 |
-
await cl.Message(
|
| 885 |
-
|
| 886 |
-
).send()
|
| 887 |
|
| 888 |
if chat_profile == 'Command-R-Plus':
|
| 889 |
await cl.ChatSettings(
|
|
@@ -904,9 +904,9 @@ async def on_chat_start():
|
|
| 904 |
),
|
| 905 |
]
|
| 906 |
).send()
|
| 907 |
-
await cl.Message(
|
| 908 |
-
|
| 909 |
-
).send()
|
| 910 |
|
| 911 |
if chat_profile == 'Command-Nightly':
|
| 912 |
await cl.ChatSettings(
|
|
@@ -927,9 +927,9 @@ async def on_chat_start():
|
|
| 927 |
),
|
| 928 |
]
|
| 929 |
).send()
|
| 930 |
-
await cl.Message(
|
| 931 |
-
|
| 932 |
-
).send()
|
| 933 |
|
| 934 |
if chat_profile == 'Command-Light-Nightly':
|
| 935 |
await cl.ChatSettings(
|
|
@@ -950,9 +950,9 @@ async def on_chat_start():
|
|
| 950 |
),
|
| 951 |
]
|
| 952 |
).send()
|
| 953 |
-
await cl.Message(
|
| 954 |
-
|
| 955 |
-
).send()
|
| 956 |
|
| 957 |
if chat_profile == 'Command-Light':
|
| 958 |
await cl.ChatSettings(
|
|
@@ -973,9 +973,9 @@ async def on_chat_start():
|
|
| 973 |
),
|
| 974 |
]
|
| 975 |
).send()
|
| 976 |
-
await cl.Message(
|
| 977 |
-
|
| 978 |
-
)
|
| 979 |
|
| 980 |
if chat_profile == 'Command-R':
|
| 981 |
await cl.ChatSettings(
|
|
@@ -996,9 +996,9 @@ async def on_chat_start():
|
|
| 996 |
),
|
| 997 |
]
|
| 998 |
).send()
|
| 999 |
-
await cl.Message(
|
| 1000 |
-
|
| 1001 |
-
).send()
|
| 1002 |
|
| 1003 |
if chat_profile == 'Command':
|
| 1004 |
await cl.ChatSettings(
|
|
@@ -1019,9 +1019,9 @@ async def on_chat_start():
|
|
| 1019 |
),
|
| 1020 |
]
|
| 1021 |
).send()
|
| 1022 |
-
await cl.Message(
|
| 1023 |
-
|
| 1024 |
-
).send()
|
| 1025 |
|
| 1026 |
if chat_profile == 'gemma2-9B':
|
| 1027 |
await cl.ChatSettings(
|
|
@@ -1042,9 +1042,9 @@ async def on_chat_start():
|
|
| 1042 |
),
|
| 1043 |
]
|
| 1044 |
).send()
|
| 1045 |
-
await cl.Message(
|
| 1046 |
-
|
| 1047 |
-
).send()
|
| 1048 |
|
| 1049 |
if chat_profile == 'gemma-7B':
|
| 1050 |
await cl.ChatSettings(
|
|
@@ -1065,9 +1065,9 @@ async def on_chat_start():
|
|
| 1065 |
),
|
| 1066 |
]
|
| 1067 |
).send()
|
| 1068 |
-
await cl.Message(
|
| 1069 |
-
|
| 1070 |
-
).send()
|
| 1071 |
if chat_profile == 'zephyr-7B':
|
| 1072 |
await cl.ChatSettings(
|
| 1073 |
[
|
|
@@ -1087,9 +1087,9 @@ async def on_chat_start():
|
|
| 1087 |
),
|
| 1088 |
]
|
| 1089 |
).send()
|
| 1090 |
-
await cl.Message(
|
| 1091 |
-
|
| 1092 |
-
).send()
|
| 1093 |
if chat_profile == 'mixtral-8x7B':
|
| 1094 |
await cl.ChatSettings(
|
| 1095 |
[
|
|
@@ -1109,9 +1109,9 @@ async def on_chat_start():
|
|
| 1109 |
),
|
| 1110 |
]
|
| 1111 |
).send()
|
| 1112 |
-
await cl.Message(
|
| 1113 |
-
|
| 1114 |
-
).send()
|
| 1115 |
|
| 1116 |
if chat_profile == 'mistral-nemo-12B':
|
| 1117 |
await cl.ChatSettings(
|
|
@@ -1132,9 +1132,9 @@ async def on_chat_start():
|
|
| 1132 |
),
|
| 1133 |
]
|
| 1134 |
).send()
|
| 1135 |
-
await cl.Message(
|
| 1136 |
-
|
| 1137 |
-
).send()
|
| 1138 |
# if chat_profile == 'Toka-353M':
|
| 1139 |
# await cl.ChatSettings(
|
| 1140 |
# [
|
|
@@ -1161,11 +1161,6 @@ async def on_chat_start():
|
|
| 1161 |
@cl.on_message
|
| 1162 |
async def main(message: cl.Message):
|
| 1163 |
chat_profile = cl.user_session.get("chat_profile")
|
| 1164 |
-
if not chat_profile or chat_profile == 'None':
|
| 1165 |
-
await cl.Message(
|
| 1166 |
-
content="Please select a model first."
|
| 1167 |
-
).send()
|
| 1168 |
-
return
|
| 1169 |
if chat_profile == 'neural-brain-AI':
|
| 1170 |
completion = openai_client.chat.completions.create(
|
| 1171 |
model="ft:gpt-3.5-turbo-1106:nb:aria1:9UWDrLJK",
|
|
|
|
| 322 |
]
|
| 323 |
).send()
|
| 324 |
|
| 325 |
+
# await cl.Message(
|
| 326 |
+
# content='my name is Dorna, Your AI Assistant designed by neural nexus team. i was made by Artin Daneshvar and Sadra Noadoust, 2 iranian students!'
|
| 327 |
+
# ).send()
|
| 328 |
if chat_profile == 'gpt4-o-mini':
|
| 329 |
await cl.ChatSettings(
|
| 330 |
[
|
|
|
|
| 344 |
),
|
| 345 |
]
|
| 346 |
).send()
|
| 347 |
+
# await cl.Message(
|
| 348 |
+
# content="Im one of the best models openai have released and i am configured by two iranian boys to help you."
|
| 349 |
+
# ).send()
|
| 350 |
|
| 351 |
# if chat_profile == 'Image-Generation':
|
| 352 |
# image = cl.Image(path='cat.png', name="result", display="inline")
|
|
|
|
| 373 |
),
|
| 374 |
]
|
| 375 |
).send()
|
| 376 |
+
# await cl.Message(
|
| 377 |
+
# content="Im OpenAI's latest and biggest model. i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 378 |
+
# ).send()
|
| 379 |
|
| 380 |
if chat_profile == 'gpt-3.5-turbo':
|
| 381 |
await cl.ChatSettings(
|
|
|
|
| 396 |
),
|
| 397 |
]
|
| 398 |
).send()
|
| 399 |
+
# await cl.Message(
|
| 400 |
+
# content="Im one of the OpenAI's models. one of the best models. i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 401 |
+
# ).send()
|
| 402 |
# if chat_profile == 'GPT-3.5-turbo-0125':
|
| 403 |
# await cl.ChatSettings(
|
| 404 |
# [
|
|
|
|
| 441 |
),
|
| 442 |
]
|
| 443 |
).send()
|
| 444 |
+
# await cl.Message(
|
| 445 |
+
# content="Im one of the OpenAI's models. one of the best models. i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 446 |
+
# ).send()
|
| 447 |
|
| 448 |
# if chat_profile == 'davinci-002':
|
| 449 |
# await cl.ChatSettings(
|
|
|
|
| 491 |
),
|
| 492 |
]
|
| 493 |
).send()
|
| 494 |
+
# await cl.Message(
|
| 495 |
+
# content='Im Qwens second generation second large model and i am configured by two iranian boys Artin Daneshvar and Sadra Noadoust to help you out!',
|
| 496 |
+
# ).send()
|
| 497 |
|
| 498 |
if chat_profile == 'Qwen2-7B':
|
| 499 |
await cl.ChatSettings(
|
|
|
|
| 514 |
),
|
| 515 |
]
|
| 516 |
).send()
|
| 517 |
+
# await cl.Message(
|
| 518 |
+
# content='Im Qwens second generation third large model and i am configured by two iranian boys Artin Daneshvar and Sadra Noadoust to help you out!',
|
| 519 |
+
# ).send()
|
| 520 |
|
| 521 |
if chat_profile == 'Qwen2-1.5B':
|
| 522 |
await cl.ChatSettings(
|
|
|
|
| 537 |
),
|
| 538 |
]
|
| 539 |
).send()
|
| 540 |
+
# await cl.Message(
|
| 541 |
+
# content='Im Qwens second generation small model and i am configured by two iranian boys Artin Daneshvar and Sadra Noadoust to help you out!',
|
| 542 |
+
# ).send()
|
| 543 |
|
| 544 |
if chat_profile == 'Qwen2-0.5B':
|
| 545 |
await cl.ChatSettings(
|
|
|
|
| 560 |
),
|
| 561 |
]
|
| 562 |
).send()
|
| 563 |
+
# await cl.Message(
|
| 564 |
+
# content='Im Qwens second generation small model and i am configured by two iranian boys Artin Daneshvar and Sadra Noadoust to help you out!',
|
| 565 |
+
# ).send()
|
| 566 |
|
| 567 |
if chat_profile == 'Qwen1.5-110B':
|
| 568 |
await cl.ChatSettings(
|
|
|
|
| 583 |
),
|
| 584 |
]
|
| 585 |
).send()
|
| 586 |
+
# await cl.Message(
|
| 587 |
+
# content='Im Qwens 1.5th generation Large model and i am configured by two iranian boys Artin Daneshvar and Sadra Noadoust to help you out!',
|
| 588 |
+
# ).send()
|
| 589 |
|
| 590 |
# if chat_profile == 'Qwen1.5-72B':
|
| 591 |
# await cl.ChatSettings(
|
|
|
|
| 629 |
),
|
| 630 |
]
|
| 631 |
).send()
|
| 632 |
+
# await cl.Message(
|
| 633 |
+
# content='Im Qwens 1.5th generation third Large model and i am configured by two iranian boys Artin Daneshvar and Sadra Noadoust to help you out!',
|
| 634 |
+
# ).send()
|
| 635 |
|
| 636 |
if chat_profile == 'Qwen1.5-2.7B':
|
| 637 |
await cl.ChatSettings(
|
|
|
|
| 652 |
),
|
| 653 |
]
|
| 654 |
).send()
|
| 655 |
+
# await cl.Message(
|
| 656 |
+
# content='Im Qwens 1.5th generation small model and i am configured by two iranian boys Artin Daneshvar and Sadra Noadoust to help you out!',
|
| 657 |
+
# ).send()
|
| 658 |
|
| 659 |
# if chat_profile == 'Qwen-72B':
|
| 660 |
# await cl.ChatSettings(
|
|
|
|
| 743 |
step=0.1,
|
| 744 |
),
|
| 745 |
]
|
| 746 |
+
# ).send()
|
| 747 |
+
# await cl.Message(
|
| 748 |
+
# content="Im the big Llama-3.1!. one of the best open source models released by Meta! i am the Big version of meta's open source LLMs., i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 749 |
+
# ).send()
|
| 750 |
|
| 751 |
if chat_profile == 'Llama-3.1-70B':
|
| 752 |
await cl.ChatSettings(
|
|
|
|
| 767 |
),
|
| 768 |
]
|
| 769 |
).send()
|
| 770 |
+
# await cl.Message(
|
| 771 |
+
# content="Im the second-big Llama-3.1!. one of the best open source models released by Meta! i am the Big version of meta's open source LLMs., i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 772 |
+
# ).send()
|
| 773 |
if chat_profile == 'Llama-3.1-8B':
|
| 774 |
await cl.ChatSettings(
|
| 775 |
[
|
|
|
|
| 789 |
),
|
| 790 |
]
|
| 791 |
).send()
|
| 792 |
+
# await cl.Message(
|
| 793 |
+
# content="Im the small Llama-3.1!. one of the best open source models released by Meta! i am the Big version of meta's open source LLMs., i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 794 |
+
# ).send()
|
| 795 |
|
| 796 |
if chat_profile == 'Llama-3-70B':
|
| 797 |
await cl.ChatSettings(
|
|
|
|
| 812 |
),
|
| 813 |
]
|
| 814 |
).send()
|
| 815 |
+
# await cl.Message(
|
| 816 |
+
# content="Im the big Llama-3!. one of the best open source models released by Meta! i am the Big version of meta's open source LLMs., i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 817 |
+
# ).send()
|
| 818 |
if chat_profile == 'Llama-3-8B':
|
| 819 |
await cl.ChatSettings(
|
| 820 |
[
|
|
|
|
| 835 |
]
|
| 836 |
).send()
|
| 837 |
|
| 838 |
+
# await cl.Message(
|
| 839 |
+
# content="Im The small Llama!. one of the best open source models released by Meta! i am the small version of meta's open source LLMs. i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 840 |
+
# ).send()
|
| 841 |
|
| 842 |
if chat_profile == 'Aya-23B':
|
| 843 |
await cl.ChatSettings(
|
|
|
|
| 858 |
),
|
| 859 |
]
|
| 860 |
).send()
|
| 861 |
+
# await cl.Message(
|
| 862 |
+
# content='Im one of the best open source models that cohere released. i am configured by 2 iranian boys named Artin Daneshvar and Sadra Noadosut to help you out!'
|
| 863 |
+
# ).send()
|
| 864 |
|
| 865 |
if chat_profile == 'Aya-35B':
|
| 866 |
await cl.ChatSettings(
|
|
|
|
| 881 |
),
|
| 882 |
]
|
| 883 |
).send()
|
| 884 |
+
# await cl.Message(
|
| 885 |
+
# content='Im one of the best open source models that cohere released. i am configured by 2 iranian boys named Artin Daneshvar and Sadra Noadosut to help you out!'
|
| 886 |
+
# ).send()
|
| 887 |
|
| 888 |
if chat_profile == 'Command-R-Plus':
|
| 889 |
await cl.ChatSettings(
|
|
|
|
| 904 |
),
|
| 905 |
]
|
| 906 |
).send()
|
| 907 |
+
# await cl.Message(
|
| 908 |
+
# content='Im one of the best open source models that cohere released. i am configured by 2 iranian boys named Artin Daneshvar and Sadra Noadosut to help you out!'
|
| 909 |
+
# ).send()
|
| 910 |
|
| 911 |
if chat_profile == 'Command-Nightly':
|
| 912 |
await cl.ChatSettings(
|
|
|
|
| 927 |
),
|
| 928 |
]
|
| 929 |
).send()
|
| 930 |
+
# await cl.Message(
|
| 931 |
+
# content='Im one of the best open source models that cohere released. i am configured by 2 iranian boys named Artin Daneshvar and Sadra Noadosut to help you out!'
|
| 932 |
+
# ).send()
|
| 933 |
|
| 934 |
if chat_profile == 'Command-Light-Nightly':
|
| 935 |
await cl.ChatSettings(
|
|
|
|
| 950 |
),
|
| 951 |
]
|
| 952 |
).send()
|
| 953 |
+
# await cl.Message(
|
| 954 |
+
# content='Im one of the best open source models that cohere released. i am configured by 2 iranian boys named Artin Daneshvar and Sadra Noadosut to help you out!'
|
| 955 |
+
# ).send()
|
| 956 |
|
| 957 |
if chat_profile == 'Command-Light':
|
| 958 |
await cl.ChatSettings(
|
|
|
|
| 973 |
),
|
| 974 |
]
|
| 975 |
).send()
|
| 976 |
+
# await cl.Message(
|
| 977 |
+
# content='Im one of the best open source models that cohere released. i am configured by 2 iranian boys named Artin Daneshvar and Sadra Noadosut to help you out!'
|
| 978 |
+
# )
|
| 979 |
|
| 980 |
if chat_profile == 'Command-R':
|
| 981 |
await cl.ChatSettings(
|
|
|
|
| 996 |
),
|
| 997 |
]
|
| 998 |
).send()
|
| 999 |
+
# await cl.Message(
|
| 1000 |
+
# content='Im one of the best open source models that cohere released. i am configured by 2 iranian boys named Artin Daneshvar and Sadra Noadosut to help you out!'
|
| 1001 |
+
# ).send()
|
| 1002 |
|
| 1003 |
if chat_profile == 'Command':
|
| 1004 |
await cl.ChatSettings(
|
|
|
|
| 1019 |
),
|
| 1020 |
]
|
| 1021 |
).send()
|
| 1022 |
+
# await cl.Message(
|
| 1023 |
+
# content='Im one of the best open source models that cohere released. i am configured by 2 iranian boys named Artin Daneshvar and Sadra Noadosut to help you out!'
|
| 1024 |
+
# ).send()
|
| 1025 |
|
| 1026 |
if chat_profile == 'gemma2-9B':
|
| 1027 |
await cl.ChatSettings(
|
|
|
|
| 1042 |
),
|
| 1043 |
]
|
| 1044 |
).send()
|
| 1045 |
+
# await cl.Message(
|
| 1046 |
+
# content="Im Gemma2. the 9B version of google second generation open source LLMs. i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 1047 |
+
# ).send()
|
| 1048 |
|
| 1049 |
if chat_profile == 'gemma-7B':
|
| 1050 |
await cl.ChatSettings(
|
|
|
|
| 1065 |
),
|
| 1066 |
]
|
| 1067 |
).send()
|
| 1068 |
+
# await cl.Message(
|
| 1069 |
+
# content="Im Gemma. the small version of google open source LLMs. i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 1070 |
+
# ).send()
|
| 1071 |
if chat_profile == 'zephyr-7B':
|
| 1072 |
await cl.ChatSettings(
|
| 1073 |
[
|
|
|
|
| 1087 |
),
|
| 1088 |
]
|
| 1089 |
).send()
|
| 1090 |
+
# await cl.Message(
|
| 1091 |
+
# content="Im Zephyr. One of the best open source LLMs. i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 1092 |
+
# ).send()
|
| 1093 |
if chat_profile == 'mixtral-8x7B':
|
| 1094 |
await cl.ChatSettings(
|
| 1095 |
[
|
|
|
|
| 1109 |
),
|
| 1110 |
]
|
| 1111 |
).send()
|
| 1112 |
+
# await cl.Message(
|
| 1113 |
+
# content="Im Mistral. the small version of Mistral Family. i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 1114 |
+
# ).send()
|
| 1115 |
|
| 1116 |
if chat_profile == 'mistral-nemo-12B':
|
| 1117 |
await cl.ChatSettings(
|
|
|
|
| 1132 |
),
|
| 1133 |
]
|
| 1134 |
).send()
|
| 1135 |
+
# await cl.Message(
|
| 1136 |
+
# content="Im Mistral nemo 12B .i was configured by Artin Daneshvar and Sadra Noadoust, 2 iranian students to help you, how can i assist you today ? "
|
| 1137 |
+
# ).send()
|
| 1138 |
# if chat_profile == 'Toka-353M':
|
| 1139 |
# await cl.ChatSettings(
|
| 1140 |
# [
|
|
|
|
| 1161 |
@cl.on_message
|
| 1162 |
async def main(message: cl.Message):
|
| 1163 |
chat_profile = cl.user_session.get("chat_profile")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1164 |
if chat_profile == 'neural-brain-AI':
|
| 1165 |
completion = openai_client.chat.completions.create(
|
| 1166 |
model="ft:gpt-3.5-turbo-1106:nb:aria1:9UWDrLJK",
|