'Alot of times the first paragraph might be the caption under an image
so we\'ll want to make sure if we\'re going to boost a parent node that
it should be connected to other paragraphs, at least for the first n
paragraphs so we\'ll want to make sure that the next sibling is a
paragraph and has at least some substantial weight to it.'

def is_boostable(self, node):

    para = 'p'
    steps_away = 0
    minimum_stopword_count = 5
    max_stepsaway_from_node = 3
    nodes = self.walk_siblings(node)
    for current_node in nodes:
        current_node_tag = self.parser.getTag(current_node)
        if (current_node_tag == para):
            if (steps_away >= max_stepsaway_from_node):
                return False
            paragraph_text = self.parser.getText(current_node)
            word_stats = self.stopwords_class(language=self.language).get_stopword_count(paragraph_text)
            if (word_stats.get_stopword_count() > minimum_stopword_count):
                return True
            steps_away += 1
    return False
