Spaces:
Sleeping
Sleeping
fix: strict grader requirements final
Browse files- env/expense_env.py +2 -2
- env/grader.py +1 -4
- env/tasks.py +0 -24
- openenv.yaml +1 -1
env/expense_env.py
CHANGED
|
@@ -1,7 +1,7 @@
|
|
| 1 |
"""Expense Environment factory for OpenEnv."""
|
| 2 |
|
| 3 |
-
from env.environment import ExpenseLeakDetectionEnv
|
| 4 |
-
|
| 5 |
|
| 6 |
def create_env(task="easy"):
|
| 7 |
"""Factory function to create environment."""
|
|
|
|
| 1 |
"""Expense Environment factory for OpenEnv."""
|
| 2 |
|
| 3 |
+
#from env.environment import ExpenseLeakDetectionEnv
|
| 4 |
+
from .environment import ExpenseLeakDetectionEnv
|
| 5 |
|
| 6 |
def create_env(task="easy"):
|
| 7 |
"""Factory function to create environment."""
|
env/grader.py
CHANGED
|
@@ -1,6 +1,3 @@
|
|
| 1 |
-
"""Grader for OpenEnv validation."""
|
| 2 |
-
|
| 3 |
-
|
| 4 |
def grade(trajectory, **kwargs):
|
| 5 |
try:
|
| 6 |
if not trajectory:
|
|
@@ -16,4 +13,4 @@ def grade(trajectory, **kwargs):
|
|
| 16 |
return min(score, 1.0)
|
| 17 |
|
| 18 |
except Exception:
|
| 19 |
-
return 0.0
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
def grade(trajectory, **kwargs):
|
| 2 |
try:
|
| 3 |
if not trajectory:
|
|
|
|
| 13 |
return min(score, 1.0)
|
| 14 |
|
| 15 |
except Exception:
|
| 16 |
+
return 0.0
|
env/tasks.py
DELETED
|
@@ -1,24 +0,0 @@
|
|
| 1 |
-
"""Task configurations for OpenEnv."""
|
| 2 |
-
|
| 3 |
-
TASKS = {
|
| 4 |
-
"easy": {
|
| 5 |
-
"description": "Easy task with clear expense patterns",
|
| 6 |
-
"max_steps": 5,
|
| 7 |
-
"difficulty": 1,
|
| 8 |
-
},
|
| 9 |
-
"medium": {
|
| 10 |
-
"description": "Medium task with ambiguous patterns",
|
| 11 |
-
"max_steps": 7,
|
| 12 |
-
"difficulty": 2,
|
| 13 |
-
},
|
| 14 |
-
"hard": {
|
| 15 |
-
"description": "Hard task with hidden and conflicting signals",
|
| 16 |
-
"max_steps": 8,
|
| 17 |
-
"difficulty": 3,
|
| 18 |
-
},
|
| 19 |
-
}
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
def get_task(name: str) -> dict:
|
| 23 |
-
"""Get task configuration by name."""
|
| 24 |
-
return TASKS.get(name, TASKS["easy"])
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
openenv.yaml
CHANGED
|
@@ -22,4 +22,4 @@ tasks:
|
|
| 22 |
grader:
|
| 23 |
type: python
|
| 24 |
module: env.grader
|
| 25 |
-
function: grade
|
|
|
|
| 22 |
grader:
|
| 23 |
type: python
|
| 24 |
module: env.grader
|
| 25 |
+
function: grade
|