Skip to main content

<Paragraphs>

Category: Object tag

The Paragraphs tag displays paragraphs of text on the labeling interface. Use to label dialogue transcripts for NLP and NER projects. The Paragraphs tag expects task data formatted as an array of objects like the following: [{ nameKey:"Authorname",nameKey: "Author name", textKey: "Text" }, ... ]

Use with the following data types: text.

Attributes​

AttributeTypeRequiredDefaultDescription
namestringyes—Name of the element
valuestringyes—Data field containing the paragraph content
valueTypejson,urlnojsonWhether the data is stored directly in uploaded JSON data or needs to be loaded from a URL
audioUrlstringno—Audio to sync phrases with
syncstringno—Object name to sync with
showPlayertrue,falsenofalseWhether to show audio player above the paragraphs. Ignored if sync object is audio
saveTextResultno,yesnoyesWhether to store labeled text along with the results. By default, doesn't store text for valueType=url
layoutnone,dialoguenononeWhether to use a dialogue-style layout or not
nameKeystringnoauthorThe key field to use for name
textKeystringnotextThe key field to use for the text
contextScrolltrue,falsenofalseTurn on contextual scroll mode

Examples​

Labeling configuration to label paragraph regions of text containing dialogue​

<View>
<Paragraphs name="dialogue-1" value="$dialogue" layout="dialogue" />
<ParagraphLabels name="importance" toName="dialogue-1">
<Label value="Important content"></Label>
<Label value="Random talk"></Label>
</ParagraphLabels>
</View>

Paragraphs with audio​

<View>
<Paragraphs audioUrl="$audio" value="$para" name="paragraphs"
layout="dialogue" textKey="text" nameKey="author"
showPlayer="true"
/>

<Choices name="choices" toName="paragraphs" choice="multiple">
<Choice value="Good quality"/>
<Choice value="Fast speech"/>
</Choices>
</View>

<!-- {"data": {
"para": [
{"text": "test 1", "author": "A", "start": 0.0, "end": 1.0},
{"text": "test 2", "author": "B", "start": 1.0, "end": 2.0},
{"text": "test 3", "author": "A", "start": 2.0, "end": 3.0}
],
"audio": "/static/samples/game.wav"
}}
-->