<commit_before><%= form_for @attachment, as: :attachment, url: path, builder: FormBuilderWithDateTimeInput do |f| %>
  <%= f.error_messages %>

	<%= f.text_field :name, :required => true %>

	<% if @attachment.new_record? %>
  <div class="row embedded-form">
    <label class="custom-file-upload">
			<span class="btn primary" id="upload_button">
				Attatchment ...
					<%= f.file_field :file, class: "upload_embedded" %>
			</span>
		</label>
		<input type="text" id="upload_file" readonly value="Select to Upload a File.">
  </div>
	<% else %>
		<%= f.text_field :mime_type,
				help_text: "Note: If you change the Mime type of a file, you might need to clear your browser's cache in order for you to see the change." %>
	<% end %>

<script>
    document.getElementById("attachment_file").onchange = function(e) {
        document.getElementById("upload_file").value = document.getElementById("attachment_file").value.split(/(\\|\/)/g).pop();
    }
</script>

  <%= f.check_box :released %>

  <%= f.submit(@attachment.new_record? ? "Upload" : "Save", class: "btn primary") %>
<% end %>
<commit_msg>Fix typo in "attachment"<commit_after><%= form_for @attachment, as: :attachment, url: path, builder: FormBuilderWithDateTimeInput do |f| %>
  <%= f.error_messages %>

	<%= f.text_field :name, :required => true %>

	<% if @attachment.new_record? %>
  <div class="row embedded-form">
    <label class="custom-file-upload">
			<span class="btn primary" id="upload_button">
				Attachment ...
					<%= f.file_field :file, class: "upload_embedded" %>
			</span>
		</label>
		<input type="text" id="upload_file" readonly value="Select to Upload a File.">
  </div>
	<% else %>
		<%= f.text_field :mime_type,
				help_text: "Note: If you change the Mime type of a file, you might need to clear your browser's cache in order for you to see the change." %>
	<% end %>

<script>
    document.getElementById("attachment_file").onchange = function(e) {
        document.getElementById("upload_file").value = document.getElementById("attachment_file").value.split(/(\\|\/)/g).pop();
    }
</script>

  <%= f.check_box :released %>

  <%= f.submit(@attachment.new_record? ? "Upload" : "Save", class: "btn primary") %>
<% end %>

{'fraction_non_alphanumeric': 0.1796028880866426, 'fraction_numerical': 0.0, 'mean_word_length': 4.061643835616438, 'pattern_counts': {'":': 0, '<': 43, '<?xml version=': 0, '>': 45, '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': '1670310', 'n_tokens_mistral': 801, 'n_tokens_neox': 705, 'n_words': 183}