<commit_before>class Answer < ActiveRecord::Base
  validates :content, presence: true
  belongs_to :question
  belongs_to :responder, class_name: "User"
  has_many :comments, as: :parent
  has_many :votes, as: :votable

  def vote_count
    votes.where(liked: true).count - votes.where(liked: false).count
  end
end<commit_msg>changed association with best answer<commit_after>class Answer < ActiveRecord::Base
  validates :content, presence: true
  belongs_to :question
  belongs_to :responder, class_name: "User"
  has_many :comments, as: :parent
  has_many :votes, as: :votable
  has_one :best_ques, class_name: "Question", foreign_key: :best_answer_id


  def vote_count
    votes.where(liked: true).count - votes.where(liked: false).count
  end
end
{'fraction_non_alphanumeric': 0.10092961487383798, 'fraction_numerical': 0.0, 'mean_word_length': 5.180327868852459, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7130159', 'n_tokens_mistral': 253, 'n_tokens_neox': 251, 'n_words': 67}