def METHOD_NAME(self, items: List[Dict[str, Any]], add_tail: bool = True) -> str:
    """
    converts a list of dicts of the format [{'class': u'col0 coll', 'str': u' \\u0159ekl'},
        {'class': u'attr', 'str': u'/j\xe1/PH-S3--1--------'},...] to a CSV compatible form
    """
    ans: List[List[str]] = []
    for item in items:
        if 'class' in item and item['class'] != 'attr':
            ans.append([str(item['str']).strip()])
        else:
            ans.append([str(item['str']).strip()])
        if add_tail:
            for posattr in item.get('posattrs', []):
                ans[-1].append(posattr)  # TODO take into account attr role
    return ' '.join('/'.join(x) for x in ans).strip()