<commit_before>'''
Created on Oct 14, 2015

@author: Ryan
'''

import praw
import pdb
import re
import os
import obot
from config_bot import *

def countComments(flat_comments): #function to count number of comments on a post
    count = 0
    for comment in flat_comments:
        count += 1
    return count

r = obot.login() #logins to /u/wacomBot using OAuth2

safe_word = "<PASSWORD>" #put the phrase OP can comment to have the bot not delete the post here

if not os.path.isfile("posts_replied_to.txt"): #creates or opens the file used to store posts replied to
    posts_replied_to = []
else:
    with open("posts_replied_to.txt", "r") as f:
        posts_replied_to = f.read()
        posts_replied_to = posts_replied_to.split("\n")
        posts_replied_to = filter(None, posts_replied_to)
<commit_msg>Removed unused imports<commit_after>'''
Created on Oct 14, 2015

@author: Ryan
'''

import praw
import re
import os
import obot

def countComments(flat_comments): #function to count number of comments on a post
    count = 0
    for comment in flat_comments:
        count += 1
    return count

r = obot.login() #logins to /u/wacomBot using OAuth2

safe_word = "<PASSWORD>" #put the phrase OP can comment to have the bot not delete the post here

if not os.path.isfile("posts_replied_to.txt"): #creates or opens the file used to store posts replied to
    posts_replied_to = []
else:
    with open("posts_replied_to.txt", "r") as f:
        posts_replied_to = f.read()
        posts_replied_to = posts_replied_to.split("\n")
        posts_replied_to = filter(None, posts_replied_to)

{'fraction_non_alphanumeric': 0.08840125391849529, 'fraction_numerical': 0.01128526645768025, 'mean_word_length': 3.6530612244897958, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '1597421', 'n_tokens_mistral': 535, 'n_tokens_neox': 536, 'n_words': 185}