def print_tree(sent, token_attr):
def __print_sent__(token, attr):<EOL><INDENT>print("<STR_LIT:{>", end="<STR_LIT:U+0020>")<EOL>[__print_sent__(t, attr) for t in token.lefts]<EOL>print(u"<STR_LIT>" % (token,token.dep_,token.tag_ if not attr else getattr(token, attr)), end="<STR_LIT>")<EOL>[__print_sent__(t, attr) for t in token.rights]<EOL>print("<STR_LIT:}>", end="<STR_LIT:U+0020>")<EOL><DEDENT>return __print_sent__(sent.root, token_attr)<EOL>
Prints sentences tree as string using token_attr from token(like pos_, tag_ etc.)

        :param sent: sentence to print
        :param token_attr: choosen attr to present for tokens(e.g. dep_, pos_, tag_, ...)