Spaces:
Paused
Paused
Commit ·
2530f40
1
Parent(s): fe9a2be
Add grader field to /tasks response for each task
Browse files- server/app.py +8 -0
server/app.py
CHANGED
|
@@ -250,6 +250,14 @@ async def tasks():
|
|
| 250 |
"requires_investigation": list(getattr(t, "requires_investigation", [])),
|
| 251 |
"regulatory_action": getattr(t, "regulatory_action", False),
|
| 252 |
"chain_total": getattr(t, "chain_total", 1),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 253 |
}
|
| 254 |
)
|
| 255 |
return {"count": len(result), "tasks": result}
|
|
|
|
| 250 |
"requires_investigation": list(getattr(t, "requires_investigation", [])),
|
| 251 |
"regulatory_action": getattr(t, "regulatory_action", False),
|
| 252 |
"chain_total": getattr(t, "chain_total", 1),
|
| 253 |
+
"grader": {
|
| 254 |
+
"type": "action_match",
|
| 255 |
+
"correct_action": t.correct_action,
|
| 256 |
+
"partial_credit": dict(getattr(t, "partial_credit_actions", {})),
|
| 257 |
+
"requires_investigation": list(getattr(t, "requires_investigation", [])),
|
| 258 |
+
"regulatory_action": getattr(t, "regulatory_action", False),
|
| 259 |
+
"key_flags": list(getattr(t, "key_flags", [])),
|
| 260 |
+
},
|
| 261 |
}
|
| 262 |
)
|
| 263 |
return {"count": len(result), "tasks": result}
|