<commit_before>#!/usr/bin/env ruby
#

#All the files in current directory
files = Dir["*"]

#Remove ruby file out of the array
files.each do |file|
    files.delete(file) if file.end_with?(".rb")
end

#Get the text from a xml element "<string>text</string>"
def get_text(str)
    return str.strip.sub("<string>", "").sub("</string>", "").strip
end
<commit_msg>Refactored rename_snippets.rb<commit_after>#!/usr/bin/env ruby
#

#All code snippet files in current directory
files = Dir["*.codesnippet"]

#Get the text from a xml element "<string>text</string>"
def get_text(str)
    return str.strip.sub("<string>", "").sub("</string>", "").strip
end

{'fraction_non_alphanumeric': 0.17592592592592593, 'fraction_numerical': 0.0, 'mean_word_length': 4.794642857142857, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, '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': '7417249', 'n_tokens_mistral': 225, 'n_tokens_neox': 216, 'n_words': 66}