MCPcopy Create free account
hub / github.com/anomalyco/opencode-bench / load_runs

Function load_runs

visualize_instability.py:24–42  ·  view source on GitHub ↗
(files: List[Path])

Source from the content-addressed store, hash-verified

22
23
24def load_runs(files: List[Path]) -> List[Dict]:
25 runs = []
26 for path in files:
27 with path.open() as fh:
28 data = json.load(fh)
29 for idx, run in enumerate(data["runs"]):
30 runs.append(
31 {
32 "file": path.name,
33 "run_index_in_file": idx,
34 "agent": run["model"],
35 "finalScore": run["summary"]["finalScore"],
36 "scores": {
37 score["assignment"]["name"]: score["averageScore"]
38 for score in run["scores"]
39 },
40 }
41 )
42 return runs
43
44
45def melt_scores(runs: List[Dict]) -> pd.DataFrame:

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected