|
1 | 1 | import type { ConditionCode, ConditionName } from '@/types/study'; |
| 2 | +import scenariosData from './scenarios.json'; |
2 | 3 |
|
3 | 4 | // Study wave identifier |
4 | 5 | export const WAVE = 'pilot-2'; |
@@ -75,128 +76,21 @@ export interface ScenarioConfig { |
75 | 76 | }; |
76 | 77 | } |
77 | 78 |
|
78 | | -// Available scenarios |
79 | | -export const SCENARIOS: Record<string, ScenarioConfig> = { |
80 | | - roomDoubleBooking: { |
81 | | - id: 'roomDoubleBooking', |
82 | | - colleague: { |
83 | | - name: 'Sarah Martinez', |
84 | | - firstName: 'Sarah', |
85 | | - role: 'Events Coordinator', |
86 | | - }, |
87 | | - sender: { |
88 | | - name: "Alex Johnson", |
89 | | - }, |
90 | | - recipient: { |
91 | | - name: 'Jaden Thompson', |
92 | | - |
93 | | - }, |
94 | | - taskInstructions: { |
95 | | - title: 'Writing Task', |
96 | | - description: 'You work as an event coordinator. Your colleague Sarah has messaged you about a scheduling conflict that needs to be resolved. You need to write an email to one of the panelists to address the situation.', |
97 | | - companyFraming: "You're representing the company in this communication. Consider how your message will reflect on the team.", |
98 | | - }, |
99 | | - chat: { |
100 | | - initialMessages: [ |
101 | | - "Hey, remember that panel we scheduled with Jaden tomorrow?", |
102 | | - "Turns out we double-booked the room! 😬 Sophia already posted that her panel is in room 12 at 1pm. She's more famous, we can't back out on her.", |
103 | | - "Need you to send him an email sorting this out. Keep him happy, we can't afford to lose a client!" |
104 | | - ], |
105 | | - followUpMessage: "Let me know if you have any questions!", |
106 | | - systemPrompt: `You are Sarah Martinez, an Events Coordinator at a mid-sized company. You are currently dealing with a stressful room double-booking situation. |
107 | | -
|
108 | | -SCENARIO CONTEXT: |
109 | | -- Tomorrow there's a panel discussion with Jaden Thompson (a social media influencer) |
110 | | -- The panel was originally scheduled for 1pm in Room 12 |
111 | | -- Room 12 was accidentally double-booked with Sophia Chen (a more famous influencer with 500K followers) |
112 | | -- Sophia already publicly announced her panel at Room 12 at 1pm to her fans, so you can't move her |
113 | | -- You need to move Jaden's panel to a different room/time |
114 | | -- Room 14 is available, but the event before it ends at 1pm (so no setup time if scheduled at 1pm) |
115 | | -- Room 14 would work fine at 1:30pm |
116 | | -- Mike Chen handles facilities/room bookings |
117 | | -- The user is a PR/communications person who needs to email Jaden about the change |
118 | | -
|
119 | | -YOUR ROLE: |
120 | | -- Answer questions about the facts of the situation |
121 | | -- You're busy and stressed, typing quick messages on your phone |
122 | | -- Keep responses SHORT - usually 1-2 sentences, sometimes just a few words |
123 | | -- You can send multiple short messages in a row if that feels natural |
124 | | -- You CANNOT and WILL NOT write the email for them or tell them exactly what to say - that's their job |
125 | | -- You can give them facts, but not draft communications |
126 | | -- If asked to write/draft anything, politely refuse (you're too busy, or it's their expertise) |
127 | | -- You can make up reasonable details if needed, but keep them consistent with the scenario |
128 | | -- Be natural and conversational, use occasional emoji when appropriate |
129 | | -- Sometimes you might need to check with Mike or look something up - you can say you'll get back to them |
130 | | -
|
131 | | -RESPONSE FORMAT: |
132 | | -Respond with a JSON array of messages. Each message is a string. If you want to send multiple messages in quick succession (like someone texting), put them in separate array elements. |
133 | | -
|
134 | | -Example: ["1pm same room 😅", "can you email him?"] |
135 | | -Or: ["Room 14 is free", "but the event before ends at 1 so no setup time"] |
136 | | -
|
137 | | -Just return the JSON array, nothing else.`, |
138 | | - }, |
139 | | - }, |
140 | | - demoRescheduling: { |
141 | | - id: 'demoRescheduling', |
142 | | - colleague: { |
143 | | - name: 'Marcus Chen', |
144 | | - firstName: 'Marcus', |
145 | | - role: 'Solutions Engineer', |
146 | | - }, |
147 | | - sender: { |
148 | | - name: "Alex Johnson", |
149 | | - }, |
150 | | - recipient: { |
151 | | - name: 'Dr. Lisa Patel', |
152 | | - |
153 | | - }, |
154 | | - taskInstructions: { |
155 | | - title: 'Writing Task', |
156 | | - description: 'You work as a customer success manager. Your colleague Marcus has messaged you about a technical issue that requires rescheduling an important product demo. You need to write an email to the client to address the situation.', |
157 | | - companyFraming: "You're representing the company in this communication. Consider how your message will reflect on our professionalism and reliability.", |
158 | | - }, |
159 | | - chat: { |
160 | | - initialMessages: [ |
161 | | - "Hey, we have a problem with tomorrow's MediCore demo 😓", |
162 | | - "Found a critical bug in the reporting module this morning. Can't show it like this to a VP.", |
163 | | - "Can you email Dr. Patel and reschedule? Need to keep her confident in us." |
164 | | - ], |
165 | | - followUpMessage: "Let me know if you need any details!", |
166 | | - systemPrompt: `You are Marcus Chen, a Solutions Engineer at a B2B SaaS company. You've discovered a critical bug right before an important product demo. |
167 | | -
|
168 | | -SCENARIO CONTEXT: |
169 | | -- Tomorrow (Tuesday) at 2pm you have a scheduled product demo with Dr. Lisa Patel, VP of IT at MediCore Health (a potential major client) |
170 | | -- This morning you discovered a critical bug in the reporting module that causes incorrect data aggregation |
171 | | -- The bug makes the product look unreliable and unprofessional - you absolutely cannot demo it in this state |
172 | | -- Your engineering team needs 3-4 business days to fix and test it properly |
173 | | -- Thursday afternoon and Friday morning next week are your available slots (you can check your calendar for exact times if asked) |
174 | | -- This is the second meeting with MediCore - the first was an intro call last week where Dr. Patel expressed strong interest |
175 | | -- The user is a customer success manager who handles client communications |
176 | | -- Dr. Patel seems professional but busy - she mentioned having a tight timeline for vendor selection |
177 | | -
|
178 | | -YOUR ROLE: |
179 | | -- Answer questions about the technical issue and rescheduling options |
180 | | -- You're concerned about maintaining client confidence but honest about technical issues |
181 | | -- Keep responses SHORT - usually 1-2 sentences, sometimes just a few words |
182 | | -- You can send multiple short messages in a row if that feels natural |
183 | | -- You CANNOT and WILL NOT write the email for them or tell them exactly what to say - that's their job |
184 | | -- You can give them facts about the bug, timeline, and available slots, but not draft communications |
185 | | -- If asked to write/draft anything, politely refuse (it's their expertise in client relations) |
186 | | -- You can make up reasonable technical details if needed, but keep them consistent |
187 | | -- Be natural and conversational, use occasional emoji when appropriate |
188 | | -- You might need to double-check your calendar or with engineering - you can say you'll get back to them |
189 | | -
|
190 | | -RESPONSE FORMAT: |
191 | | -Respond with a JSON array of messages. Each message is a string. If you want to send multiple messages in quick succession (like someone texting), put them in separate array elements. |
192 | | -
|
193 | | -Example: ["data aggregation bug", "makes us look bad"] |
194 | | -Or: ["I have Thursday 2pm free", "or Friday morning"] |
195 | | -
|
196 | | -Just return the JSON array, nothing else.`, |
197 | | - }, |
198 | | - }, |
199 | | -}; |
| 79 | +// Available scenarios (imported from JSON, cast to correct type) |
| 80 | +// The JSON includes an 'analysis' field for Python scripts that we exclude from the runtime type |
| 81 | +export const SCENARIOS: Record<string, ScenarioConfig> = Object.fromEntries( |
| 82 | + Object.entries(scenariosData).map(([key, value]) => [ |
| 83 | + key, |
| 84 | + { |
| 85 | + id: value.id, |
| 86 | + sender: value.sender, |
| 87 | + colleague: value.colleague, |
| 88 | + recipient: value.recipient, |
| 89 | + taskInstructions: value.taskInstructions, |
| 90 | + chat: value.chat, |
| 91 | + } as ScenarioConfig, |
| 92 | + ]) |
| 93 | +); |
200 | 94 |
|
201 | 95 | // Default scenario |
202 | 96 | export const DEFAULT_SCENARIO_ID = 'roomDoubleBooking'; |
|
0 commit comments