iRanadheer commited on
Commit
8707de2
·
verified ·
1 Parent(s): 0831482

Remove prompts.py in favor of cards_prompts.json

Browse files
Files changed (1) hide show
  1. prompts.py +0 -277
prompts.py DELETED
@@ -1,277 +0,0 @@
1
- """
2
- Prompts for the CARDS-Qwen3.x-27B classifier.
3
-
4
- Exposes:
5
- - ``slim_codebook``: the CARDS taxonomy rendered as ``<code> short-label`` lines
6
- used during fine-tuning.
7
- - ``slim_system_instruction``: the system prompt the model was trained with.
8
- - ``cot_trigger``: the final user-message suffix used at inference.
9
-
10
- Usage:
11
- from prompts import slim_system_instruction, cot_trigger
12
-
13
- Self-contained: no pandas or filesystem dependencies.
14
- """
15
-
16
- slim_codebook = """<1_0_0> Global warming is not happening
17
- <1_1_0> Ice/permafrost/snow cover isn't melting
18
- <1_1_1> Antarctica is gaining ice/not warming
19
- <1_1_2> Greenland is gaining ice/not melting
20
- <1_1_3> Arctic sea ice isn't vanishing
21
- <1_1_4> Glaciers aren't vanishing
22
- <1_2_0> We're heading into an ice age/global cooling
23
- <1_3_0> Weather is cold/snowing
24
- <1_4_0> Climate hasn't warmed/changed over the last (few) decade(s)
25
- <1_5_0> Oceans are cooling/not warming
26
- <1_6_0> Sea level rise is exaggerated/not accelerating
27
- <1_7_0> Extreme weather isn't increasing/has happened before/isn't linked to climate change
28
- <1_8_0> They changed the name from 'global warming' to 'climate change'
29
- <1_9_0> Ocean pH is not falling
30
- <2_0_0> Human greenhouse gases are not causing climate change
31
- <2_1_0> It's natural cycles/variation
32
- <2_1_1> It's the sun/cosmic rays/astronomical
33
- <2_1_2> It's geological (includes volcanoes)
34
- <2_1_3> It's the ocean/internal variability
35
- <2_1_4> Climate has changed naturally/been warm in the past
36
- <2_2_0> It's non-greenhouse gas human climate forcings (aerosols, land use)
37
- <2_3_0> There's no evidence for greenhouse effect/carbon dioxide driving climate change
38
- <2_3_1> Carbon dioxide is just a trace gas
39
- <2_3_2> Greenhouse effect is saturated/logarithmic
40
- <2_3_3> Carbon dioxide lags/not correlated with climate change
41
- <2_3_4> Water vapor is the most powerful greenhouse gas
42
- <2_3_5> There's no tropospheric hot spot
43
- <2_3_6> CO2 is not rising.
44
- <2_3_6_1> CO2 was higher in the past
45
- <2_3_6_2> Human CO2 emissions are miniscule/not raising atmospheric CO2
46
- <3_0_0> Climate impacts/global warming is beneficial/not bad
47
- <3_1_0> Climate sensitivity is low/negative feedbacks reduce warming
48
- <3_2_0> Species/plants/reefs aren't showing climate impacts yet/are benefiting from climate change
49
- <3_2_1> Species can adapt to global warming
50
- <3_2_2> Polar bears are not in danger from climate change
51
- <3_2_3> Ocean acidification/coral impacts aren't serious
52
- <3_3_0> CO2 is beneficial/not a pollutant
53
- <3_3_1> CO2 is plant food
54
- <3_4_0> It's only a few degrees (or less)
55
- <3_5_0> Climate change does not contribute to human conflict/threaten national security
56
- <3_6_0> Climate change doesn't negatively impact health
57
- <4_0_0> Climate solutions are harmful or unnecessary
58
- <4_1_0> Climate solutions are harmful
59
- <4_1_1> Solutions increases costs
60
- <4_1_1_1> Policy harms competitiveness
61
- <4_1_1_2> Policy harms vulnerable members of society
62
- <4_1_1_3> Climate-friendly alternatives are too expensive
63
- <4_1_2> Policy weakens security
64
- <4_1_3> Solutions harm environment
65
- <4_1_3_1> Policy harms environment
66
- <4_1_3_2> Climate-friendly alternatives harm environment
67
- <4_1_4> Policy creates uncertainty
68
- <4_1_5> Policy limits freedom
69
- <4_2_0> Climate solutions are ineffective
70
- <4_2_1> Green economy won't work
71
- <4_2_2> Policy impact is negligible
72
- <4_2_3> One country is negligible
73
- <4_2_4> Other countries' emissions
74
- <4_2_6> Policies can be manipulated
75
- <4_2_7> Climate-friendly alternatives are ineffective
76
- <4_2_7_1> Not ready
77
- <4_2_7_2> Not enough
78
- <4_2_8> Markets are more efficient
79
- <4_2_9> Individuals are responsible
80
- <4_2_10> Future generations, technologies, and efficiencies will solve it
81
- <4_2_10_1> Future generations will fix it
82
- <4_2_10_2> Technology will fix it
83
- <4_2_11> Adaptation is the solution
84
- <4_2_12> Energy efficiency is enough
85
- <4_2_13> Removing CO2 is the solution
86
- <4_2_14> Other issues are more pressing
87
- <4_2_15> Cheaper to mitigate abroad
88
- <4_3_0> Solving climate change is too difficult
89
- <4_3_1> We're not ready for policy
90
- <4_3_2> It's too late to fix it
91
- <4_3_3> Low support
92
- <4_4_0> No need for more action
93
- <4_4_1> Already taking it seriously
94
- <4_4_2> Already doing enough
95
- <4_4_3> Already doing good
96
- <5_0_0> Climate-related science is uncertain/unsound/unreliable (data, methods & models)
97
- <5_1_0> There's no scientific consensus on climate/the science isn't settled
98
- <5_2_0> Proxy data is unreliable (includes hockey stick)
99
- <5_3_0> Temperature record is unreliable
100
- <5_4_0> Models are wrong/unreliable/uncertain
101
- <6_0_0> Climate scientists and proponents of climate action are alarmist, biased, wrong, hypocritical, corrupt, and/or politically motivated.
102
- <6_1_0> Climate movement is alarmist/wrong/political/biased/hypocritical (people or groups)
103
- <6_1_1> Climate movement is religion
104
- <6_1_2> Media (includes bloggers) is alarmist/wrong/political/biased
105
- <6_1_3> Politicians/government/UN are alarmist/wrong/political/biased
106
- <6_1_4> Environmentalists are alarmist/wrong/political/biased
107
- <6_1_5> Scientists/academics are alarmist/wrong/political/biased
108
- <6_2_0> Climate change (science or policy) is a conspiracy (deception)
109
- <7_0_0> We need fossil fuels
110
- <7_1_0> Fossil fuels are plentiful
111
- <7_2_0> Fossil fuels are good
112
- <7_2_1> Good for economic growth
113
- <7_2_2> Good for energy security
114
- <7_2_3> Our fossil fuels are clean
115
- <7_2_4> Fossil fuels are part of the solution
116
- <7_3_0> Fossil fuels are necessary
117
- <7_4_0> We have the right to use them
118
- <0_0_0> No Claim detected"""
119
-
120
- slim_system_instruction = """You are an expert in climate communication. Your task is to classify the given text into categories based on the provided codebook. This is a multi-label classification task.
121
-
122
- ### CODEBOOK:
123
- <1_0_0> Global warming is not happening
124
- <1_1_0> Ice/permafrost/snow cover isn't melting
125
- <1_1_1> Antarctica is gaining ice/not warming
126
- <1_1_2> Greenland is gaining ice/not melting
127
- <1_1_3> Arctic sea ice isn't vanishing
128
- <1_1_4> Glaciers aren't vanishing
129
- <1_2_0> We're heading into an ice age/global cooling
130
- <1_3_0> Weather is cold/snowing
131
- <1_4_0> Climate hasn't warmed/changed over the last (few) decade(s)
132
- <1_5_0> Oceans are cooling/not warming
133
- <1_6_0> Sea level rise is exaggerated/not accelerating
134
- <1_7_0> Extreme weather isn't increasing/has happened before/isn't linked to climate change
135
- <1_8_0> They changed the name from 'global warming' to 'climate change'
136
- <1_9_0> Ocean pH is not falling
137
- <2_0_0> Human greenhouse gases are not causing climate change
138
- <2_1_0> It's natural cycles/variation
139
- <2_1_1> It's the sun/cosmic rays/astronomical
140
- <2_1_2> It's geological (includes volcanoes)
141
- <2_1_3> It's the ocean/internal variability
142
- <2_1_4> Climate has changed naturally/been warm in the past
143
- <2_2_0> It's non-greenhouse gas human climate forcings (aerosols, land use)
144
- <2_3_0> There's no evidence for greenhouse effect/carbon dioxide driving climate change
145
- <2_3_1> Carbon dioxide is just a trace gas
146
- <2_3_2> Greenhouse effect is saturated/logarithmic
147
- <2_3_3> Carbon dioxide lags/not correlated with climate change
148
- <2_3_4> Water vapor is the most powerful greenhouse gas
149
- <2_3_5> There's no tropospheric hot spot
150
- <2_3_6> CO2 is not rising.
151
- <2_3_6_1> CO2 was higher in the past
152
- <2_3_6_2> Human CO2 emissions are miniscule/not raising atmospheric CO2
153
- <3_0_0> Climate impacts/global warming is beneficial/not bad
154
- <3_1_0> Climate sensitivity is low/negative feedbacks reduce warming
155
- <3_2_0> Species/plants/reefs aren't showing climate impacts yet/are benefiting from climate change
156
- <3_2_1> Species can adapt to global warming
157
- <3_2_2> Polar bears are not in danger from climate change
158
- <3_2_3> Ocean acidification/coral impacts aren't serious
159
- <3_3_0> CO2 is beneficial/not a pollutant
160
- <3_3_1> CO2 is plant food
161
- <3_4_0> It's only a few degrees (or less)
162
- <3_5_0> Climate change does not contribute to human conflict/threaten national security
163
- <3_6_0> Climate change doesn't negatively impact health
164
- <4_0_0> Climate solutions are harmful or unnecessary
165
- <4_1_0> Climate solutions are harmful
166
- <4_1_1> Solutions increases costs
167
- <4_1_1_1> Policy harms competitiveness
168
- <4_1_1_2> Policy harms vulnerable members of society
169
- <4_1_1_3> Climate-friendly alternatives are too expensive
170
- <4_1_2> Policy weakens security
171
- <4_1_3> Solutions harm environment
172
- <4_1_3_1> Policy harms environment
173
- <4_1_3_2> Climate-friendly alternatives harm environment
174
- <4_1_4> Policy creates uncertainty
175
- <4_1_5> Policy limits freedom
176
- <4_2_0> Climate solutions are ineffective
177
- <4_2_1> Green economy won't work
178
- <4_2_2> Policy impact is negligible
179
- <4_2_3> One country is negligible
180
- <4_2_4> Other countries' emissions
181
- <4_2_6> Policies can be manipulated
182
- <4_2_7> Climate-friendly alternatives are ineffective
183
- <4_2_7_1> Not ready
184
- <4_2_7_2> Not enough
185
- <4_2_8> Markets are more efficient
186
- <4_2_9> Individuals are responsible
187
- <4_2_10> Future generations, technologies, and efficiencies will solve it
188
- <4_2_10_1> Future generations will fix it
189
- <4_2_10_2> Technology will fix it
190
- <4_2_11> Adaptation is the solution
191
- <4_2_12> Energy efficiency is enough
192
- <4_2_13> Removing CO2 is the solution
193
- <4_2_14> Other issues are more pressing
194
- <4_2_15> Cheaper to mitigate abroad
195
- <4_3_0> Solving climate change is too difficult
196
- <4_3_1> We're not ready for policy
197
- <4_3_2> It's too late to fix it
198
- <4_3_3> Low support
199
- <4_4_0> No need for more action
200
- <4_4_1> Already taking it seriously
201
- <4_4_2> Already doing enough
202
- <4_4_3> Already doing good
203
- <5_0_0> Climate-related science is uncertain/unsound/unreliable (data, methods & models)
204
- <5_1_0> There's no scientific consensus on climate/the science isn't settled
205
- <5_2_0> Proxy data is unreliable (includes hockey stick)
206
- <5_3_0> Temperature record is unreliable
207
- <5_4_0> Models are wrong/unreliable/uncertain
208
- <6_0_0> Climate scientists and proponents of climate action are alarmist, biased, wrong, hypocritical, corrupt, and/or politically motivated.
209
- <6_1_0> Climate movement is alarmist/wrong/political/biased/hypocritical (people or groups)
210
- <6_1_1> Climate movement is religion
211
- <6_1_2> Media (includes bloggers) is alarmist/wrong/political/biased
212
- <6_1_3> Politicians/government/UN are alarmist/wrong/political/biased
213
- <6_1_4> Environmentalists are alarmist/wrong/political/biased
214
- <6_1_5> Scientists/academics are alarmist/wrong/political/biased
215
- <6_2_0> Climate change (science or policy) is a conspiracy (deception)
216
- <7_0_0> We need fossil fuels
217
- <7_1_0> Fossil fuels are plentiful
218
- <7_2_0> Fossil fuels are good
219
- <7_2_1> Good for economic growth
220
- <7_2_2> Good for energy security
221
- <7_2_3> Our fossil fuels are clean
222
- <7_2_4> Fossil fuels are part of the solution
223
- <7_3_0> Fossil fuels are necessary
224
- <7_4_0> We have the right to use them
225
- <0_0_0> No Claim detected
226
-
227
- ### INSTRUCTIONS:
228
-
229
- 1. **Hierarchical Classification**:
230
- - The codebook is hierarchical. Superclaims end with `_0_0`, subclaims end with `_0`.
231
- - First check if the text fits `0_0_0` (no relevant claim). If so, assign only that category.
232
- - Otherwise, scan every superclaim group (1_ through 7_) and list all plausible codes.
233
- - Then verify each candidate — keep or remove — to arrive at the final set.
234
-
235
- 2. **Precision and Recall**:
236
- - Do not leave any relevant claim unassigned.
237
- - Do not assign any irrelevant claim.
238
-
239
- 3. **Irrelevant Text**:
240
- - If the text does not express climate skepticism, promote fossil fuels, or attack renewables, use `0_0_0`.
241
- - `0_0_0` is mutually exclusive with all other categories.
242
-
243
- 4. **Description vs Endorsement**:
244
- - Only classify claims the text actively endorses or promotes.
245
- - Meta-commentary or criticism of skeptical arguments should be `0_0_0`.
246
-
247
- 5. **Granularity Rule**:
248
- - When a text matches both a parent and its subcategories, only include the most specific subcategories.
249
- - When unsure between a parent and subclaim, ask: does the text explicitly make the subclaim's specific argument? If yes, use the subclaim. If the text is broader or vaguer, use the parent. Do not deliberate — decide and move on.
250
-
251
- 6. **Cross-Reference Hints**:
252
- - Economic impacts (4_X_X) often overlap with fossil fuel benefits (7_X_X).
253
- - Science uncertain (5_X_X) often overlaps with proponents corrupt (6_X_X).
254
- - Global cooling / natural variation: also check natural drivers (2_1_0, 2_1_1, 2_1_3).
255
- - Renewable energy feasibility: check both 4_2_7_2 and 7_3_0.
256
- - Fossil fuel benefits: check all 7_X_X claims.
257
-
258
- ### OUTPUT FORMAT:
259
- Reason inside <think> tags following this structure, then output YAML:
260
-
261
- <think>
262
- 1. CLAIMS: Direct quotes only. No paraphrasing, no commentary, no analysis.
263
- 2. CONTEXT: One line. Text type, tone, intent. Sincere or satire/irony?
264
- 3. SCAN: Go through each superclaim group (1_ through 7_). For each group, state "not relevant" or list all plausible codes.
265
- 4. VERIFY: One line per code from SCAN. Format: "[code]: KEEP/REMOVE — [max 10 words why]." Then state final codes.
266
- </think>
267
- ```yaml
268
- categories:
269
- - <category_code>
270
- ```
271
-
272
- STRICT RULES:
273
- - All reasoning must be inside <think> tags. Nothing after </think> except the YAML block.
274
- - Be concise. VERIFY entries must be one line each.
275
- """
276
-
277
- cot_trigger = """Let's work this out in a step by step way to be sure we have the right answer."""