* 截断内容到指定长度
(content: string, maxLength: number = 500)
| 136 | * 截断内容到指定长度 |
| 137 | */ |
| 138 | function truncateContent(content: string, maxLength: number = 500): string { |
| 139 | if (content.length <= maxLength) return content |
| 140 | return content.slice(0, maxLength) + '...' |
| 141 | } |
| 142 | |
| 143 | /** |
| 144 | * 使用 AI 生成文本(简化的非流式调用) |
no outgoing calls
no test coverage detected