<commit_before>class PhyloTreeNg < ApplicationRecord
  has_and_belongs_to_many :pipeline_runs
  belongs_to :user
  belongs_to :project

  # Newick file representing the phylo tree.
  OUTPUT_NEWICK = "phylotree-ng-1.phylotree.nwk".freeze
  # Metadata JSON for reference sequences downloaded from the NCBI database.
  OUTPUT_NCBI_METADATA = "phylotree-ng-1.ncbi_metadata.json".freeze
  # SKA distances output for download
  OUTPUT_SKA_DISTANCES = "phylotree-ng-1.ska.distances.tsv".freeze
  # SKA variants output for download
  OUTPUT_SKA_VARIANTS = "phylotree-ng-1.ska.variants.aln".freeze
  # PNG of a genomic distance matrix (heatmap) for when the samples are too divergent.
  OUTPUT_CLUSTERMAP_PNG = "phylotree-ng-1.clustermap.png".freeze
  # SVG of a genomic distance matrix (heatmap) for when the samples are too divergent.
  OUTPUT_CLUSTERMAP_SVG = "phylotree-ng-1.clustermap.svg".freeze

  INPUT_ERRORS = {
    "TooDivergentError" => "Sequences are too divergent to create a single phylo tree",
  }.freeze

  validates :status, inclusion: { in: WorkflowRun::STATUS.values }
  validates :name, presence: true
<commit_msg>Update output constants for PhyloTreeNg (#1020)<commit_after>class PhyloTreeNg < ApplicationRecord
  has_and_belongs_to_many :pipeline_runs
  belongs_to :user
  belongs_to :project

  # Newick file representing the phylo tree.
  OUTPUT_NEWICK = "phylotree.phylotree_newick".freeze
  # Metadata JSON for reference sequences downloaded from the NCBI database.
  OUTPUT_NCBI_METADATA = "phylotree.ncbi_metadata_json".freeze
  # SKA distances output for download
  OUTPUT_SKA_DISTANCES = "phylotree.ska_distances".freeze
  # SKA variants output for download
  OUTPUT_SKA_VARIANTS = "phylotree.variants".freeze
  # PNG of a genomic distance matrix (heatmap) for when the samples are too divergent.
  OUTPUT_CLUSTERMAP_PNG = "phylotree.clustermap_png".freeze
  # SVG of a genomic distance matrix (heatmap) for when the samples are too divergent.
  OUTPUT_CLUSTERMAP_SVG = "phylotree.clustermap_svg".freeze

  INPUT_ERRORS = {
    "TooDivergentError" => "Sequences are too divergent to create a single phylo tree",
  }.freeze

  validates :status, inclusion: { in: WorkflowRun::STATUS.values }
  validates :name, presence: true

{'fraction_non_alphanumeric': 0.07610146862483311, 'fraction_numerical': 0.004450378282153983, 'mean_word_length': 4.884816753926701, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2731433', 'n_tokens_mistral': 816, 'n_tokens_neox': 744, 'n_words': 199}