dolphinium
commited on
Commit
·
59c2657
1
Parent(s):
83ba6f2
give true sample for facet generation.
Browse files- llm_prompts.py +36 -0
llm_prompts.py
CHANGED
@@ -195,6 +195,42 @@ This is the most critical part of your task. A bad choice leads to a useless, bo
|
|
195 |
}}
|
196 |
}}
|
197 |
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
198 |
---
|
199 |
### YOUR TASK
|
200 |
|
|
|
195 |
}}
|
196 |
}}
|
197 |
```
|
198 |
+
|
199 |
+
|
200 |
+
**User Query 4 :** "Compare deal values for injection vs oral related to infection news."
|
201 |
+
**Correct JSON Output 3:**
|
202 |
+
```json
|
203 |
+
{{
|
204 |
+
"reasoning": {{
|
205 |
+
"dimension_choice": "The user wants to compare deal values for 'injection' vs 'oral' drug delivery methods within 'infection' news. The user has specified the comparison ('injection vs oral'), making 'route_branch' the appropriate analysis dimension to directly reflect this comparison. Using 'drug_delivery_branch' would be too granular for this high-level comparison.",
|
206 |
+
"measure_choice": "The user explicitly asks to compare 'deal values', so 'sum(total_deal_value_in_million)' is the correct measure."
|
207 |
+
}},
|
208 |
+
"analysis_dimension": "route_branch",
|
209 |
+
"analysis_measure": "sum(total_deal_value_in_million)",
|
210 |
+
"sort_field_for_examples": "total_deal_value_in_million",
|
211 |
+
"query_filter": "drug_delivery_branch_s:(injection OR oral) AND therapeutic_category_s:infections AND date_year:2025 AND total_deal_value_in_million:[0 TO *]",
|
212 |
+
"quantitative_request": {{
|
213 |
+
"json.facet": {{
|
214 |
+
"deal_values_by_route": {{
|
215 |
+
"type": "terms",
|
216 |
+
"field": "route_branch",
|
217 |
+
"limit": 10,
|
218 |
+
"sort": "total_deal_value desc",
|
219 |
+
"facet": {{
|
220 |
+
"total_deal_value": "sum(total_deal_value_in_million)"
|
221 |
+
}}
|
222 |
+
}}
|
223 |
+
}}
|
224 |
+
}},
|
225 |
+
"qualitative_request": {{
|
226 |
+
"group": true,
|
227 |
+
"group.field": "route_branch",
|
228 |
+
"group.limit": 1,
|
229 |
+
"group.sort": "sum(total_deal_value_in_million) desc",
|
230 |
+
"sort": "total_deal_value_in_million desc"
|
231 |
+
}}
|
232 |
+
}}
|
233 |
+
```
|
234 |
---
|
235 |
### YOUR TASK
|
236 |
|