pollix commited on
Commit
544840e
·
verified ·
1 Parent(s): 11cbe6f

stuntd demo Space

Browse files
.ruff_cache/0.16.8/11323576657175475506 CHANGED
Binary files a/.ruff_cache/0.16.8/11323576657175475506 and b/.ruff_cache/0.16.8/11323576657175475506 differ
 
app.py CHANGED
@@ -371,7 +371,10 @@ def _question_chart(asked: Asked) -> str:
371
  _text(LABEL_RIGHT, y + 13, label, 11, INK, "bold" if is_teacher else "normal", "end")
372
  )
373
  if is_teacher:
374
- body.append(f'<circle cx="8" cy="{y + 9:.1f}" r="3.5" fill="{INK}"/>')
 
 
 
375
  body.extend(_bar_pair(y, asked.zero_shot.get(label, 0.0), asked.head.get(label, 0.0)))
376
  if hidden:
377
  note = f"{hidden} more options, each below the ones shown"
 
371
  _text(LABEL_RIGHT, y + 13, label, 11, INK, "bold" if is_teacher else "normal", "end")
372
  )
373
  if is_teacher:
374
+ # Beside the label rather than at the chart edge, where it read as a stray dot.
375
+ # The label is right-aligned, so its left end is estimated from its length.
376
+ x = max(8.0, LABEL_RIGHT - 6.3 * len(label) - 9)
377
+ body.append(f'<circle cx="{x:.1f}" cy="{y + 9:.1f}" r="3.5" fill="{INK}"/>')
378
  body.extend(_bar_pair(y, asked.zero_shot.get(label, 0.0), asked.head.get(label, 0.0)))
379
  if hidden:
380
  note = f"{hidden} more options, each below the ones shown"