<commit_before><div class="nested-fields">
    <%= f.input :name %>
    <%= f.input :age %>
    <%= f.collection_select :gender_id, @genders, :id, :sex, {prompt: "Choose a Gender"} %>
    <%= f.input :ethnicity_id,:collection => @ethnicities,:label_method => :title,:value_method => :id,:label => "Race" ,:include_blank => false, :selected => 1 %>
    <%= f.input :unarmed %>
    <%= f.input :mentally_ill %>
    <%= f.input :homeless%>
    <%= f.input :veteran %>
    <div class='btn-group'>
      <%= link_to_remove_association "remove subject", f, class: 'btn btn-primary btn-remove' %>
    </div>

</div>
<br><br>
<commit_msg>Correctly Select Subject Race/Gender Values on Edit (#4066)<commit_after><% current_subject = f.object %>
<div class="nested-fields">
    <%= f.input :name %>
    <%= f.input :age %>
    <%= f.collection_select :gender_id, @genders, :id, :sex, {prompt: "Choose a Gender", selected: current_subject.gender_id} %>
    <%= f.input :ethnicity_id,:collection => @ethnicities,:label_method => :title,:value_method => :id,:label => "Race" ,:include_blank => false, :selected => current_subject.ethnicity_id %>
    <%= f.input :unarmed %>
    <%= f.input :mentally_ill %>
    <%= f.input :homeless%>
    <%= f.input :veteran %>
    <div class='btn-group'>
      <%= link_to_remove_association "remove subject", f, class: 'btn btn-primary btn-remove' %>
    </div>

</div>
<br><br>

{'fraction_non_alphanumeric': 0.20384889522451888, 'fraction_numerical': 0.003563791874554526, 'mean_word_length': 4.032258064516129, 'pattern_counts': {'":': 0, '<': 34, '<?xml version=': 0, '>': 46, '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': '4726252', 'n_tokens_mistral': 553, 'n_tokens_neox': 503, 'n_words': 104}