With lot of training sentences in your intent, adding some over time, it become hard to know if you ever add same one, have some like the new one, etc.
Here is a little hack to get your training sorted alphabetically in your intent.
You first need a working python environement.
Create a folder with three files:
- On your intent, export training sentence, ctrlA+ctrlC
- Past them in sentences.txt
- Run the python script
- ctrlA+ctrlC sentencesOrdered.txt
- On the console, delete all training sentences, import, ctrlV
Here is the python script:
#!/usr/bin/python # -*- coding: utf-8 -*- import sys, os import io with io.open('sentences.txt', 'rt', newline='') as f: sentences = f.readlines() sentences.sort() newFile = '' for sent in sentences: sent = sent.replace("\r\n", "\n") newFile += sent open('sentencesOrdered.txt', 'w').write(newFile)