ForcePilot/backend
郭诣 75b5f36f09 fix(knowledge): 修复 general parser 分块超限导致 LightRAG 索引失败
naive_merge 不保证输出 chunk 在 token 上限内,当单行内容超过
chunk_token_num 时会产生超大 chunk,导致 LightRAG 报错
"Chunk token length 3140 exceeds chunk_token_size 1200"。

- nlp.py: 新增 hard_split_by_token_limit 公共硬切分函数
- general.py: 新增 _ensure_chunk_token_limit 兜底保护
- laws.py: 删除本地重复函数,改用 nlp 版本(DRY)
2026-05-01 22:31:58 +08:00
..
package fix(knowledge): 修复 general parser 分块超限导致 LightRAG 索引失败 2026-05-01 22:31:58 +08:00
server fix(model): 修复刷新模型缓存接口 NameError: model_cache is not defined 2026-04-27 06:45:34 +08:00
test fix(knowledge): 修复 general parser 分块超限导致 LightRAG 索引失败 2026-05-01 22:31:58 +08:00
.python-version refactor: 将后端代码迁移至 backend 目录 2026-03-24 11:08:12 +08:00
pyproject.toml feat(release): 更新版本号至 0.6.2 2026-04-27 02:27:28 +08:00
uv.lock feat(release): 更新版本号至 0.6.2 2026-04-27 02:27:28 +08:00