java.lang.Object
de.seggebaeing.sqlanalyzer.logic.util.CsvExporter

public class CsvExporter extends Object
Utility for exporting evaluation scores to a CSV file.
Since:
1.0
Author:
Felix Seggebäing
  • Constructor Details

    • CsvExporter

      public CsvExporter()
  • Method Details

    • exportScoresCsv

      public static void exportScoresCsv(Map<GeneratedQuery,Double> results, String path) throws IOException
      Exports generated query scores to a CSV file named output.csv in the given directory.

      Writes a header and one row per entry with columns: score,llm_name,prompt_type_name,sample_query_name,sample_query_complexity. Creates parent directories if needed and overwrites any existing file.

      Parameters:
      results - map of GeneratedQuery to its score
      path - target directory for the CSV file
      Throws:
      IOException - if creating directories or writing the file fails
      Implementation Note:
      Assumes each GeneratedQuery has non-null generator, prompt, type, and sample query.