# YAML document splitter

- Human page: https://happytails.ai/en/data-tools/yaml-document-splitter/
- Markdown: https://happytails.ai/en/data-tools/yaml-document-splitter.md
- Structured JSON: https://happytails.ai/agents/en/data-tools/yaml-document-splitter/index.json
- Visibility: public

## Tool capabilities

| Property | Value |
| --- | --- |
| Tool ID | `yaml-document-splitter` |
| Category | data-tools |
| Implementation | Registered implementation. Registration alone is not a production-quality guarantee. |
| Browser execution | Automatic updates after valid input or file selection. |
| Browser processing | Browser; see tool notes for network behavior. |
| HTTP API | Not callable through HTTP. |
| Browser-agent interface | run_current_tool |

### Implementation notes

Up to 100 YAML documents, 50,000 parsed nodes and 64 nesting levels. Diagnostic reports omit source text and key values. No application schema is checked. Split a valid stream into numbered YAML files using parser document boundaries. Scalar values, directives, comments, line endings and document markers remain in their original source slices. Concatenate the numbered downloads to recover the source exactly. Custom tags and complex keys are preserved without interpretation. Syntax errors and scalar duplicate keys block splitting. Collection-valued or unsupported typed keys are preserved without equality analysis. Runs on your device. No remote configuration, repository or credentials are queried. Up to 1,000,000 input characters; output files are limited to 4,000,000 characters each.

### Inputs and settings

Text input: Configuration text.

Example or placeholder shown in the interface (not a validated fixture):

```text
# first
---
name: alpha
...
# second
---
name: beta
```

Paste text to process locally. Review the supported syntax and the result before downloading. Results update as you type. Up to 1,000,000 characters.

No additional settings are declared for this tool.

### Browser-agent workflow

1. Open the human page in a browser that supports WebMCP.
2. Discover the interface exposed by that page; use its actual schema.
3. Select files on the page first when the tool requires files.
4. Call `run_current_tool` with valid input and settings.
5. Inspect the returned result or error and the displayed output. Retrieve files from the displayed download links.

Calls do not automatically copy or download results. Browser permissions still apply. Interface availability alone is not proof of successful execution.

### Planning specification

Up to 100 documents, 50,000 parsed nodes and 64 nesting levels. Diagnostic reports omit source text and key values. No application schema is checked. Runs on your device with no configuration, repository or credential lookups. Up to 1,000,000 input characters and 4,000,000 characters per output file.

This describes intended requirements. Use the implementation notes, interface schema and observed output to determine current support.

### Complete machine-readable capability record

```json
{
  "id": "yaml-document-splitter",
  "category": "data-tools",
  "built": true,
  "requirements": "Up to 100 documents, 50,000 parsed nodes and 64 nesting levels. Diagnostic reports omit source text and key values. No application schema is checked. Runs on your device with no configuration, repository or credential lookups. Up to 1,000,000 input characters and 4,000,000 characters per output file.",
  "implementation": {
    "fields": [],
    "live": true,
    "presentation": "metrics",
    "note": "Up to 100 YAML documents, 50,000 parsed nodes and 64 nesting levels. Diagnostic reports omit source text and key values. No application schema is checked. Split a valid stream into numbered YAML files using parser document boundaries. Scalar values, directives, comments, line endings and document markers remain in their original source slices. Concatenate the numbered downloads to recover the source exactly. Custom tags and complex keys are preserved without interpretation. Syntax errors and scalar duplicate keys block splitting. Collection-valued or unsupported typed keys are preserved without equality analysis. Runs on your device. No remote configuration, repository or credentials are queried. Up to 1,000,000 input characters; output files are limited to 4,000,000 characters each.",
    "experience": {
      "automatic": true,
      "single": false,
      "inputMaxLength": 1000000,
      "inputMode": "text",
      "label": "Configuration text",
      "placeholder": "# first\n---\nname: alpha\n...\n# second\n---\nname: beta\n",
      "help": "Paste text to process locally. Review the supported syntax and the result before downloading. Results update as you type. Up to 1,000,000 characters.",
      "action": null
    },
    "mode": "automatic",
    "interactive": false
  },
  "execution": "Browser interface",
  "api": null,
  "browser_agent": {
    "supported": true,
    "name": "run_current_tool",
    "discovery": "WebMCP on the human page in a supporting browser",
    "verification": "See audit/API-AUDIT.md; availability is not verification"
  }
}
```

## Page guide

Separate a YAML stream into numbered files using parsed document boundaries. Retain source text, comments, directives and document markers.

How can we improve this tool?

Report a problem or share an idea.

Please leave out private information. Your message and the tool name go to our team via PostHog.

### How to use YAML document splitter

1. Paste a multi-document YAML stream.
2. Review the document count and any parser issues.
3. Download the numbered files and source-boundary report.

## Useful next steps

- [YAML anchor resolver](https://happytails.ai/en/data-tools/yaml-anchor-resolver/) ([Markdown](https://happytails.ai/en/data-tools/yaml-anchor-resolver.md))

- [YAML duplicate key checker](https://happytails.ai/en/data-tools/yaml-duplicate-key-checker/) ([Markdown](https://happytails.ai/en/data-tools/yaml-duplicate-key-checker.md))

## Split documents without mistaking text for a separator

Paste a YAML stream with multiple documents. The parser identifies boundaries, so a --- sequence inside a quoted or block scalar is not treated as a new document. Explicit empty documents are retained.

### Keep the original source slices

The numbered downloads retain their original text, including line endings, directives, comments, custom tags, scalar spelling and document markers. The report records each file’s source offsets. Concatenating the files in numerical order reconstructs the original text exactly.

### Check syntax before making files

Syntax errors, unresolved aliases and duplicate scalar keys block splitting. Collection-valued or unsupported typed keys are preserved without equality analysis. Custom tags and complex keys are preserved without interpreting their application meaning. No application schema or external reference is loaded.
