style: ruff-format the leaderboard renderer

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Umutcan Edizsalan
2026-07-23 16:17:08 +03:00
co-authored by Cursor
parent bae0750d4c
commit d5a0ff5109
+2 -7
View File
@@ -68,9 +68,7 @@ def render_chart(data: dict[str, Any], output: Path) -> None:
projects = sorted(data["projects"], key=lambda item: item["score"])
total = len(projects)
# rank 1 = highest score (drawn topmost by barh with ascending sort)
labels = [
f"{total - index}. {item['repository']}" for index, item in enumerate(projects)
]
labels = [f"{total - index}. {item['repository']}" for index, item in enumerate(projects)]
scores = [item["score"] for item in projects]
grades = [item["evidence_grade"] for item in projects]
# leaderboard palette by rank (rank 1 first), canvas/LLM-benchmark style
@@ -85,10 +83,7 @@ def render_chart(data: dict[str, Any], output: Path) -> None:
"#f0876e", # 8 salmon
"#8957e5", # 9 purple
]
colors = [
rank_palette[(total - 1 - index) % len(rank_palette)]
for index in range(total)
]
colors = [rank_palette[(total - 1 - index) % len(rank_palette)] for index in range(total)]
fig, ax = plt.subplots(figsize=(12, 0.62 * total + 2.4), constrained_layout=True)
fig.patch.set_facecolor("#0d1117")