Overseas access: www.kdjingpai.com
Bookmark Us
Current Position:fig. beginning " AI Answers

使用Yek时如何自定义分块大小?有哪些参数可以调整?

2025-09-10 1.8 K

分块参数配置

Yek提供灵活的分块控制选项:

Core parameters

  • –max-size:设置每块最大值(如10MB/128KB/1GB)
  • –tokens:启用按近似LLM令牌计数分块
  • –output-dir:指定输出目录(默认使用临时目录)

Typical usage scenarios

  1. 基础分块:yek --max-size 5MB
  2. 精确令牌控制:yek --max-size 128K --tokens src/
  3. 多目录处理:yek src/ tests/ --max-size 100KB

建议根据目标LLM的上下文窗口大小调整分块参数,例如GPT-4推荐128K令牌的块大小。

Recommended

Can't find AI tools? Try here!

Just type in the keyword Accessibility Bing SearchYou can quickly find all the AI tools on this site.

Top

en_USEnglish