<commit_before>module Questionable
  class QuestionGroup < ActiveRecord::Base

    #has_many :group_assignments
    #has_many :subjects, :through => :group_assignments

    #belongs_to :group, :polymorphic => true
    #belongs_to :assignment
    has_many :assignments
    has_many :subjects, :through => :assignments
    has_many :questions, :through => :assignments, :include => :answers
    has_many :answers, :through => :assignments

    has_ancestry :orphan_strategy => :destroy, :cache_depth => true

    attr_accessible :title, :note, :category, :group, :group_id, :group_type, :position

    validates_presence_of :title
=begin
    def answers_for_user(user)
      answers = self.answers.where(user_id: user.id)
      answers.any? ? answers : [self.answers.build(user_id: user.id)]
    end
=end<commit_msg>Remove include :answers from groups<commit_after>module Questionable
  class QuestionGroup < ActiveRecord::Base

    #has_many :group_assignments
    #has_many :subjects, :through => :group_assignments

    #belongs_to :group, :polymorphic => true
    #belongs_to :assignment
    has_many :assignments
    has_many :subjects, :through => :assignments
    has_many :questions, :through => :assignments
    has_many :answers, :through => :assignments

    has_ancestry :orphan_strategy => :destroy, :cache_depth => true

    attr_accessible :title, :note, :category, :group, :group_id, :group_type, :position

    validates_presence_of :title
=begin
    def answers_for_user(user)
      answers = self.answers.where(user_id: user.id)
      answers.any? ? answers : [self.answers.build(user_id: user.id)]
    end
=end
{'fraction_non_alphanumeric': 0.11056511056511056, 'fraction_numerical': 0.0, 'mean_word_length': 4.43, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 18, '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': '3941324', 'n_tokens_mistral': 548, 'n_tokens_neox': 525, 'n_words': 121}