ishaan-007 commited on
Commit
db21b05
Β·
1 Parent(s): 588b72a

add UI changes for visualizing combined results

Browse files
Files changed (1) hide show
  1. app.py +15 -2
app.py CHANGED
@@ -112,6 +112,15 @@ CHECKPOINT_FILES = [
112
  ]
113
 
114
  CHART_OPTIONS = [
 
 
 
 
 
 
 
 
 
115
  ("Intertopic Map β€” Abstract", "chart_abstract_intertopic.html"),
116
  ("Frequency Bars β€” Abstract", "chart_abstract_bars.html"),
117
  ("Hierarchy / Treemap β€” Abstract", "chart_abstract_hierarchy.html"),
@@ -317,7 +326,7 @@ def load_review_table() -> pd.DataFrame:
317
  "Approve": False, "Rename To": ""})
318
  return pd.DataFrame(rows, columns=REVIEW_COLUMNS) if rows else EMPTY_REVIEW_DF
319
 
320
- for rk in ("abstract", "title"):
321
  p = f"labels_{rk}.json"
322
  if os.path.exists(p):
323
  data = json.loads(open(p, encoding="utf-8").read())
@@ -338,7 +347,11 @@ def load_review_table() -> pd.DataFrame:
338
 
339
  def load_council_report() -> str:
340
  """Return a detailed HTML report of the AI Council arguments."""
341
- possible_files = ["labels_abstract.json", "labels_title.json", "council_labels_abstract.json"]
 
 
 
 
342
  found = [f for f in possible_files if os.path.exists(f)]
343
  if not found:
344
  return "<div style='padding:40px;text-align:center;color:#4a5a7a;'>AI Council arguments will appear here after Phase 3 or after running DBSCAN Council.</div>"
 
112
  ]
113
 
114
  CHART_OPTIONS = [
115
+ #NEW CHARTs
116
+ ("Intertopic Map β€” Combined", "chart_combined_intertopic.html"),
117
+ ("Frequency Bars β€” Combined", "chart_combined_bars.html"),
118
+ ("Hierarchy / Treemap β€” Combined", "chart_combined_hierarchy.html"),
119
+ ("Similarity Heatmap β€” Combined", "chart_combined_heatmap.html"),
120
+ ("DBSCAN Cluster Scatter β€” Combined", "chart_combined_dbscan_scatter.html"),
121
+ ("DBSCAN vs Agglomerative β€” Combined", "chart_combined_dbscan_comparison.html"),
122
+ ("Refined Sub-Clusters β€” Combined", "chart_combined_refined.html"),
123
+ #ORIGINAL ONES
124
  ("Intertopic Map β€” Abstract", "chart_abstract_intertopic.html"),
125
  ("Frequency Bars β€” Abstract", "chart_abstract_bars.html"),
126
  ("Hierarchy / Treemap β€” Abstract", "chart_abstract_hierarchy.html"),
 
326
  "Approve": False, "Rename To": ""})
327
  return pd.DataFrame(rows, columns=REVIEW_COLUMNS) if rows else EMPTY_REVIEW_DF
328
 
329
+ for rk in ("combined", "abstract", "title"):
330
  p = f"labels_{rk}.json"
331
  if os.path.exists(p):
332
  data = json.loads(open(p, encoding="utf-8").read())
 
347
 
348
  def load_council_report() -> str:
349
  """Return a detailed HTML report of the AI Council arguments."""
350
+ possible_files = [
351
+ "council_labels_combined.json", "labels_combined.json",
352
+ "council_labels_abstract.json", "labels_abstract.json",
353
+ "council_labels_title.json", "labels_title.json"
354
+ ]
355
  found = [f for f in possible_files if os.path.exists(f)]
356
  if not found:
357
  return "<div style='padding:40px;text-align:center;color:#4a5a7a;'>AI Council arguments will appear here after Phase 3 or after running DBSCAN Council.</div>"