Spaces:
Sleeping
Sleeping
Paramveer singh commited on
Commit ·
a310069
1
Parent(s): 7fa260d
Fix: Register 3 tasks in yaml and clamp grader scores to (0,1)
Browse files- env.py +3 -2
- openenv.yaml +4 -0
env.py
CHANGED
|
@@ -164,7 +164,8 @@ class DataPrivacyEnv:
|
|
| 164 |
# Ensure floating point math doesn't result in something like 0.999000001
|
| 165 |
score = round(score, 3)
|
| 166 |
|
| 167 |
-
#
|
| 168 |
-
|
|
|
|
| 169 |
|
| 170 |
return final_reward, done
|
|
|
|
| 164 |
# Ensure floating point math doesn't result in something like 0.999000001
|
| 165 |
score = round(score, 3)
|
| 166 |
|
| 167 |
+
# --- THE FIX: CLAMP SCORE BETWEEN 0.01 AND 0.99 ---
|
| 168 |
+
# The validator strictly rejects 0.0 and 1.0
|
| 169 |
+
final_reward = max(0.01, min(0.99, score))
|
| 170 |
|
| 171 |
return final_reward, done
|
openenv.yaml
CHANGED
|
@@ -2,3 +2,7 @@ name: data-privacy-env
|
|
| 2 |
version: 1.0.0
|
| 3 |
type: environment
|
| 4 |
entry_point: server.app:app
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2 |
version: 1.0.0
|
| 3 |
type: environment
|
| 4 |
entry_point: server.app:app
|
| 5 |
+
tasks:
|
| 6 |
+
- name: easy_log_redaction
|
| 7 |
+
- name: medium_crm_audit
|
| 8 |
+
- name: hard_right_to_be_forgotten
|