MoonshotAI / MoonshotAI/kimi-code
支持通过 Read 实验性抽取 PDF 文本
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 7.5k
- Forks
- 1.2k
- Avg merge
- 11h 53m
- Merged PRs (30d)
- 350
Description
What feature would you like to see?
希望为现有 Read 工具增加实验性 PDF 文本抽取能力。
目前 Kimi Code 可以通过 Read 读取文本文件,通过 ReadMediaFile 读取图片和视频,但 PDF 文件还没有进入内
置文件阅读工作流。PDF 在 coding agent 工作流中很常见,例如论文、规格说明、报告、手册、API 文档等。如果没
有一条内置的 Read 路径,Agent 往往会退回到通过 Bash 手动调用 pdftotext,这会绕过 Read 已有的行
号、分页和 <system> 状态输出契约。
codex中默认处理PDF的工作流就是调用pdftotext工具,我觉得这个工具非常好用
Additional information
依赖策略建议:
这个功能不需要在 npm 或 native 安装流程中内置 Poppler。pdftotext 可以保持为可选运行时依赖;缺失时给出安
装指引即可。
原因:
- native single-binary 当前主要打包 JavaScript 和选定的 npm-native assets,不适合作为通用系统二进制分发
器。 - Poppler 是 GPL 许可,直接把
pdftotext二进制打进 Kimi Code 的 MIT 发行包,会带来平台、体积、动态库、
更新和许可证合规复杂度。
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the existing Read and ReadMediaFile implementations and their line-number, pagination, and output contracts. Review how Bash currently invokes pdftotext, then define the optional-runtime behavior and installation guidance; done means PDF text uses the Read workflow without bundling Poppler.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100