def METHOD_NAME(self, max_length: int = 500, include_code=True) -> str:
    """"输出文本"""
    current_length = 0
    output = self.header + "\n\n" if self.header else ""
    for para in self.content:
        content = para.text
        # 超过长度限制了就中断，这里其实没考虑代码段 ``` 多出来的 10 个字符
        if current_length + len(content) > max_length:
            break
        if para.type == ContentType.Code and include_code:
            output += f"\n```\n{content}\n```\n"
        else:
            output += content + "\n"
        current_length += len(content)
    return output