Where: faircode/cli.py (profile/compare subparsers), faircode/report.py, faircode/benchmark.py.
Current gap: profile and compare only support --json and --html output formats; report.py has no to_csv/compare_to_csv function (grep -n "csv" faircode/report.py returns nothing). Meanwhile faircode benchmark writes results_fairness.csv, results_performance.csv, and summary.csv as its primary output format - CSV is already an established, expected export convention elsewhere in this same CLI, just not on the two commands analysts are most likely to want it from (e.g. to drop a dimension's per-group shares/CIs straight into a spreadsheet or BI tool).
Repro:
$ grep -n "\-\-json\|\-\-html\|\-\-csv" faircode/cli.py
... --json and --html present on profile/compare; no --csv anywhere on either
$ grep -n "csv" faircode/report.py
(no output)
Suggested approach: add --csv PATH to both profile and compare that writes a flat table (one row per group per dimension: dimension,kind,label,count,share,ci_low,ci_high,under_represented,small_group, plus a section for flags), following the same "write to PATH, print a confirmation to stderr" pattern already used for --html.
Where:
faircode/cli.py(profile/compare subparsers),faircode/report.py,faircode/benchmark.py.Current gap:
profileandcompareonly support--jsonand--htmloutput formats;report.pyhas noto_csv/compare_to_csvfunction (grep -n "csv" faircode/report.pyreturns nothing). Meanwhilefaircode benchmarkwritesresults_fairness.csv,results_performance.csv, andsummary.csvas its primary output format - CSV is already an established, expected export convention elsewhere in this same CLI, just not on the two commands analysts are most likely to want it from (e.g. to drop a dimension's per-group shares/CIs straight into a spreadsheet or BI tool).Repro:
Suggested approach: add
--csv PATHto bothprofileandcomparethat writes a flat table (one row per group per dimension:dimension,kind,label,count,share,ci_low,ci_high,under_represented,small_group, plus a section for flags), following the same "write to PATH, print a confirmation to stderr" pattern already used for--html.