# prodigy splitting sentences for annotation

**URL:** https://support.prodi.gy/t/prodigy-splitting-sentences-for-annotation/336
**Category:** Uncategorized
**Tags:** enhancement, usage, done
**Created:** [February 23, 2018, 6:26pm UTC](https://support.prodi.gy/t/prodigy-splitting-sentences-for-annotation/336 "2018-02-23T18:26:23Z")
**Posts on this page:** 1
**Showing post:** 11

<div class="post-metadata">

### Author: ![ines](https://sea2.discourse-cdn.com/flex020/user_avatar/support.prodi.gy/ines/32/3_2.png) [@ines](https://support.prodi.gy/u/ines)
#### Post date: [December 9, 2019, 5:04pm UTC](https://support.prodi.gy/t/prodigy-splitting-sentences-for-annotation/336/11 "2019-12-09T17:04:35Z")

</div>

> [@yishairasowsky](#):
>
> So, please, how do I set the amount of displayed text per annotation click to be less?  
> I tried changing the setting `split_sents_threshold` in the prodigy.json file, of which I have a copy in my home directory and also in my local project's folder (is that superfluous?).

Hi! The `ner.manual` recipe doesn't split sentences – that's why the `split_sents_threshold` has no effect here. There are two options to split your texts:

1. Update the recipe in `recipes/ner.py` (or use [this template](https://github.com/explosion/prodigy-recipes/blob/master/ner/ner_manual.py) to write your own custom version of `ner.manual`). The `split_sentences` preprocessor takes an `nlp` object that can split sentences (either with a parser or the sentencizer) and your stream. For example:

```python
from prodigy.components.preprocess import split_sentences

# after your stream is loaded etc.
stream = split_sentences(nlp, stream)

```

1. Preprocess your JSONL file in Python and use spaCy to split sentences. Then save it to a new file and use that in Prodigy. For example:

```python
import spacy
import srsly # to easily read/write JSONL etc.

nlp = spacy.load("en_core_web_sm") # or whatever you need
examples = srsly.read_jsonl("./Lease-7.jsonl")
texts = (eg["text"] for eg in examples)

new_examples = []
for doc in nlp.pipe(texts):
    for sent in doc.sents:
        new_examples.append({"text": sent.text})
srsly.write_jsonl("./Lease-7-with-sentences.jsonl", new_examples)

```

---

_[View the full topic](https://support.prodi.gy/t/prodigy-splitting-sentences-for-annotation/336)._
