Skip to content

Commit

Permalink
feat(README.md): add documentation for --split-chunks option to imp…
Browse files Browse the repository at this point in the history
…rove usability
  • Loading branch information
bounoable committed Apr 18, 2024
1 parent 48ab849 commit eeef9d1
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,17 @@ option is not provided, the translated content will be printed to stdout.
dragoman source.json --out target.json
```

**`--split-chunks`**

Split the source document into chunks before translating. This can help to fit
the documents into the context size of OpenAI's models. Each line that starts
with one of the provided prefixes will create a new chunk.

**Example: Split a Markdown file into chunks when encountering H2 and H3 headings:**
```bash
dragoman source.json --split-chunks "## " --split-chunks "### "
```

**`-u` or `--update`**

Enable this option to only translate missing fields from the source file that
Expand Down

0 comments on commit eeef9d1

Please sign in to comment.