Skip to content

字符文本分割器节点#

¥Character Text Splitter node

使用“字符文本分割器”节点,根据字符分割文档数据。

¥Use the Character Text Splitter node to split document data based on characters.

本页提供“字符文本分割器”节点的节点参数以及更多资源的链接。

¥On this page, you'll find the node parameters for the Character Text Splitter node, and links to more resources.

Parameter resolution in sub-nodes

Sub-nodes behave differently to other nodes when processing multiple items using an expression.

Most nodes, including root nodes, take any number of items as input, process these items, and output the results. You can use expressions to refer to input items, and the node resolves the expression for each item in turn. For example, given an input of five name values, the expression {{ $json.name }} resolves to each name in turn.

In sub-nodes, the expression always resolves to the first item. For example, given an input of five name values, the expression {{ $json.name }} always resolves to the first name.

节点参数#

¥Node parameters

  • 分隔符:选择用于将文档拆分为单独项的分隔符。

¥Separator: Select the separator used to split the document into separate items.

  • 块大小:输入每个数据块的字符数。

¥Chunk Size: Enter the number of characters in each chunk.

  • 块重叠:输入数据块之间的重叠比例。

¥Chunk Overlap: Enter how much overlap to have between chunks.

模板和示例#

¥Templates and examples

Template widget placeholder.

相关资源#

¥Related resources

请参阅 LangChain 的文本分割器文档LangChain 的字符文本分割 API 文档 获取有关服务的更多信息。

¥Refer to LangChain's text splitter documentation and LangChain's API documentation for character text splitting for more information about the service.

View n8n's Advanced AI documentation.