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

Function loadDataset

scripts/build-workflow-matrix.ts:73–86  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

71}
72
73function loadDataset(): DatasetEntry[] {
74 const raw = readFileSync(new URL("../dataset.yaml", import.meta.url), "utf8");
75 const parsed = YAML.parse(raw);
76 if (!Array.isArray(parsed)) {
77 throw new Error("dataset.yaml must contain an array.");
78 }
79
80 return parsed
81 .map((entry) => entry?.repo)
82 .filter(
83 (repo): repo is string => typeof repo === "string" && repo.length > 0,
84 )
85 .map((repo) => ({ repo }));
86}
87
88async function main(): Promise<void> {
89 // Read inputs from stdin

Callers 1

mainFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected