Zekun Wu
commited on
Commit
·
1ad6de6
1
Parent(s):
e19912c
update
Browse files- app.py +2 -2
- example_data.json +151 -80
app.py
CHANGED
@@ -5,7 +5,7 @@ from openai import AzureOpenAI
|
|
5 |
from model import invoke, create_models, configure_settings, load_documents_and_create_index, \
|
6 |
create_chat_prompt_template, execute_query
|
7 |
|
8 |
-
client = AzureOpenAI(azure_endpoint =
|
9 |
|
10 |
|
11 |
example_profile = {
|
@@ -161,7 +161,7 @@ def main_app():
|
|
161 |
|
162 |
with st.chat_message("assistant"):
|
163 |
stream = client.chat.completions.create(
|
164 |
-
model="
|
165 |
temperature=st.session_state['temperature'],
|
166 |
max_tokens=1000, # Adjust based on desired response length
|
167 |
frequency_penalty=0.2, # To avoid repetition
|
|
|
5 |
from model import invoke, create_models, configure_settings, load_documents_and_create_index, \
|
6 |
create_chat_prompt_template, execute_query
|
7 |
|
8 |
+
client = AzureOpenAI(azure_endpoint = os.environ.get("AZURE_OPENAI_ENDPOINT_RAG"),api_key=os.getenv("AZURE_OPENAI_KEY"), api_version="2024-02-15-preview")
|
9 |
|
10 |
|
11 |
example_profile = {
|
|
|
161 |
|
162 |
with st.chat_message("assistant"):
|
163 |
stream = client.chat.completions.create(
|
164 |
+
model="personality_gpt4o",
|
165 |
temperature=st.session_state['temperature'],
|
166 |
max_tokens=1000, # Adjust based on desired response length
|
167 |
frequency_penalty=0.2, # To avoid repetition
|
example_data.json
CHANGED
@@ -1,83 +1,154 @@
|
|
1 |
{
|
2 |
-
"
|
3 |
-
"
|
4 |
-
"
|
5 |
-
"
|
|
|
|
|
|
|
6 |
},
|
7 |
-
"
|
8 |
-
"
|
9 |
-
"
|
|
|
|
|
10 |
},
|
11 |
-
"
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
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 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
{
|
2 |
+
"Description": {
|
3 |
+
"MAIN PROFILE DESCRIPTIONS": {
|
4 |
+
"VISION": "Sees the ‘big picture’ and maintains line of sight. Alignment of goals and actions",
|
5 |
+
"IDEATION": "Generates original and/or innovative ideas; makes unexpected connections",
|
6 |
+
"OPPORTUNISM": "Alert to opportunity; prepared to seize opportunities",
|
7 |
+
"DRIVE": "Strong desire to accomplish goals, Propensity to act decisively and get things done; proactive rather than reactive",
|
8 |
+
"RESILIENCE": "Remains calm and optimistic under pressure, Perseveres in the face of adversity, Recovers from setbacks"
|
9 |
},
|
10 |
+
"RED FLAG DESCRIPTIONS": {
|
11 |
+
"HUBRIS": "Conceit and self-importance, Overestimation of knowledge and/or ability in respect of tasks, Misplaced belief in unique or exceptional abilities",
|
12 |
+
"MERCURIAL": "Given to sudden changes of mood, behaviour or direction, Given to unconventional or strange behaviour or beliefs, Difficult to predict and/or surprising",
|
13 |
+
"DOMINANT": "Forceful, insistent, domineering, Hostile and argumentative, Unyielding in the face of evidence or argument",
|
14 |
+
"MACHIAVELLIAN": "Deliberate deceitfulness in the pursuit on one’s interest; acting in bad faith, Ruthless pursuit of own interests regardless of considerations of right or wrong, General distrust of the motives of others; attribution of bad faith"
|
15 |
},
|
16 |
+
"Team": [
|
17 |
+
{
|
18 |
+
"name": "JAMES ARTHUR",
|
19 |
+
"main_profile": {
|
20 |
+
"VISION": {
|
21 |
+
"score": "HIGH"
|
22 |
+
},
|
23 |
+
"IDEATION": {
|
24 |
+
"score": "HIGH"
|
25 |
+
},
|
26 |
+
"OPPORTUNISM": {
|
27 |
+
"score": "HIGH"
|
28 |
+
},
|
29 |
+
"DRIVE": {
|
30 |
+
"score": "HIGH"
|
31 |
+
},
|
32 |
+
"RESILIENCE": {
|
33 |
+
"score": "HIGH"
|
34 |
+
}
|
35 |
+
},
|
36 |
+
"red_flag": {
|
37 |
+
"HUBRIS": {
|
38 |
+
"score": "HIGH"
|
39 |
+
},
|
40 |
+
"MERCURIAL": {
|
41 |
+
"score": "LOW"
|
42 |
+
},
|
43 |
+
"DOMINANT": {
|
44 |
+
"score": "HIGH"
|
45 |
+
},
|
46 |
+
"MACHIAVELLIAN": {
|
47 |
+
"score": "AVERAGE"
|
48 |
+
}
|
49 |
+
}
|
50 |
+
},
|
51 |
+
{
|
52 |
+
"name": "LOUSIE HART",
|
53 |
+
"main_profile": {
|
54 |
+
"VISION": {
|
55 |
+
"score": "AVERAGE"
|
56 |
+
},
|
57 |
+
"IDEATION": {
|
58 |
+
"score": "AVERAGE"
|
59 |
+
},
|
60 |
+
"OPPORTUNISM": {
|
61 |
+
"score": "AVERAGE"
|
62 |
+
},
|
63 |
+
"DRIVE": {
|
64 |
+
"score": "HIGH"
|
65 |
+
},
|
66 |
+
"RESILIENCE": {
|
67 |
+
"score": "HIGH"
|
68 |
+
}
|
69 |
+
},
|
70 |
+
"red_flag": {
|
71 |
+
"HUBRIS": {
|
72 |
+
"score": "AVERAGE"
|
73 |
+
},
|
74 |
+
"MERCURIAL": {
|
75 |
+
"score": "LOW"
|
76 |
+
},
|
77 |
+
"DOMINANT": {
|
78 |
+
"score": "HIGH"
|
79 |
+
},
|
80 |
+
"MACHIAVELLIAN": {
|
81 |
+
"score": "LOW"
|
82 |
+
}
|
83 |
+
}
|
84 |
+
},
|
85 |
+
{
|
86 |
+
"name": "SIMONE LEVY",
|
87 |
+
"main_profile": {
|
88 |
+
"VISION": {
|
89 |
+
"score": "LOW"
|
90 |
+
},
|
91 |
+
"IDEATION": {
|
92 |
+
"score": "AVERAGE"
|
93 |
+
},
|
94 |
+
"OPPORTUNISM": {
|
95 |
+
"score": "LOW"
|
96 |
+
},
|
97 |
+
"DRIVE": {
|
98 |
+
"score": "AVERAGE"
|
99 |
+
},
|
100 |
+
"RESILIENCE": {
|
101 |
+
"score": "LOW"
|
102 |
+
}
|
103 |
+
},
|
104 |
+
"red_flag": {
|
105 |
+
"HUBRIS": {
|
106 |
+
"score": "LOW"
|
107 |
+
},
|
108 |
+
"MERCURIAL": {
|
109 |
+
"score": "LOW"
|
110 |
+
},
|
111 |
+
"DOMINANT": {
|
112 |
+
"score": "LOW"
|
113 |
+
},
|
114 |
+
"MACHIAVELLIAN": {
|
115 |
+
"score": "LOW"
|
116 |
+
}
|
117 |
+
}
|
118 |
+
},
|
119 |
+
{
|
120 |
+
"name": "Uri Lef",
|
121 |
+
"main_profile": {
|
122 |
+
"VISION": {
|
123 |
+
"score": "HIGH"
|
124 |
+
},
|
125 |
+
"IDEATION": {
|
126 |
+
"score": "HIGH"
|
127 |
+
},
|
128 |
+
"OPPORTUNISM": {
|
129 |
+
"score": "HIGH"
|
130 |
+
},
|
131 |
+
"DRIVE": {
|
132 |
+
"score": "AVERAGE"
|
133 |
+
},
|
134 |
+
"RESILIENCE": {
|
135 |
+
"score": "LOW"
|
136 |
+
}
|
137 |
+
},
|
138 |
+
"red_flag": {
|
139 |
+
"HUBRIS": {
|
140 |
+
"score": "AVERAGE"
|
141 |
+
},
|
142 |
+
"MERCURIAL": {
|
143 |
+
"score": "HIGH"
|
144 |
+
},
|
145 |
+
"DOMINANT": {
|
146 |
+
"score": "HIGH"
|
147 |
+
},
|
148 |
+
"MACHIAVELLIAN": {
|
149 |
+
"score": "AVERAGE"
|
150 |
+
}
|
151 |
+
}
|
152 |
+
}
|
153 |
+
}
|
154 |
+
}
|