<commit_before>from __future__ import absolute_import
from __future__ import print_function
from __future__ import division

from collections import defaultdict
from itertools import product

from alg_breadth_first_search import traverse_bfs

WORDS_FILE = 'four_letter_words.txt'


def read_words():
    """Read words file with producing a generator."""
    with open(WORDS_FILE) as f:
        for line in f:
            yield line[:-1]


def build_word_ladder_graph(words):
    vertex_dict = defaultdict(list)
    graph_dict = defaultdict(set)

    # Create buckets of words that are different by one letter.
    for word in words:
        for i in xrange(len(word)):<commit_msg>Add comment for skipping the end line<commit_after>from __future__ import absolute_import
from __future__ import print_function
from __future__ import division

from collections import defaultdict
from itertools import product

from alg_breadth_first_search import traverse_bfs

WORDS_FILE = 'four_letter_words.txt'


def read_words():
    """Read words file with producing a generator."""
    with open(WORDS_FILE) as f:
        for line in f:
            # Skip the end line symbol.
            yield line[:-1]


def build_word_ladder_graph(words):
    vertex_dict = defaultdict(list)
    graph_dict = defaultdict(set)

    # Create buckets of words that are different by one letter.
    for word in words:
        for i in xrange(len(word)):
{'fraction_non_alphanumeric': 0.060393258426966294, 'fraction_numerical': 0.0014044943820224719, 'mean_word_length': 3.7818791946308723, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '1964423', 'n_tokens_mistral': 411, 'n_tokens_neox': 401, 'n_words': 148}