def random(self, tag='nigel'):
        snips = self.get_snips_by_tag(tag)
        if snips:
            link = snips[Random().randint(0, len(snips)-1)]
            # parse image link
            md_regex = r'!\[.*\]\((.*)\)\s?'
            match = re.match(md_regex, link.get('code'))
            if match:
                return str(' '.join([x for x in match.groups()])) # throws exception for unicode
Returns the content of a random snip
dataset/ETHPy150Open honza/nigel/matchers/gifter.py/GifterMatcher.random