Quick Tutorial, Part 3

Quick Start Tutorial, Part 3

Making New Phrase Sets

Once no more text to be converted to spintax can be found by "Magic Find", new phrase sets need to be created. whirlDOC has a convenient way to do this. Document text selected with the mouse is put into the spintax panel where new phrases can be added to complete a phrase set. Selection can be done with the usual method of holding the left mouse button down then dragging the mouse, but single words can be selected by right clicking. After the phrase set is complete in the spintax panel, the "Find Phrases" button can then be used to highlight text in the document that matches phrases in the panel. The highlights, just like highlights made by "Magic Find", can be converted into spintax with the "Create Spintax" button. This process is demonstrated in the steps below.

Steps to add spintax

The spintax panel is cleared using the "Clear Panel" button before selecting text. This is necessary because selected text is only put in the panel when it is clear or a new phrase set is being created. This prevents text from being put into the panel accidentally when using cut, copy, and paste during regular editing.

In the steps above, synonym phrases are typed into the spintax panel. Additional text in the document can also be selected with the mouse to add phrases to the panel.

The steps show the text selection remaining selected as the spintax panel is edited. Different operating systems handle this differently. For example, Windows will deselect the text when the panel is clicked on to edit it. The "Find Phrases" step will highlight the old selection along with all other occurrences of phrases in the spintax panel.

Capital Letters in Spintax

Normally phrases in a phrase set are in lower case. whirlDOC handles capitalizing spintax when it appears at the beginning of a sentence. To this end, selected text is changed to all lower case when it is put into the spintax panel. Proper nouns are a special case that needs to be handled manually. This next series of steps shows a proper name, "King Cole", being changed to spintax and how letters in the spintax panel have to be capitalized.

Steps to handle capitals

Multiple Word Phrases

This next set of steps demonstrates a common situation, document text with words that can be rearranged without the meaning being changed. The phrase "pipe and bowl" can be replaced with "bowl and pipe". A spintax phrase set can easily be created that contains both phrases, and one phrase will be randomly selected when spinning the document.

Steps to handle multiple word phrases

Changing Spintax

This next series of steps demonstrates how spintax can be modified. When a spintax segment is left clicked with the mouse, it and all other segments that use the same phrase set are marked in red and the phrase set is loaded into the spintax panel. The panel can then be edited to change the phrase set used by the spintax. All spintax segments that use the phrase set are changed immediately as the panel is changed. There is no button to save the changes.

The steps show how the previously created spintax for "King Cole" can have another phrase added.

Steps to change spintax

Testing the Document

Before spinning document variations for actual use, it is a good idea to test the document to make sure the spintax and variants do not introduce grammar mistakes or other problems. The "Test" button spins a test variation and places it in the test pane, which can be switched to with a tab next to the editing pane. Every time the "Test" button is clicked, a new variation will be made, so many variations can be viewed to ensure the document is readable and without mistakes.

Testing spintax documents

Spinning Variations

Document variations are spun with the "Whirl" button, which pops up a dialog similar to the one below. This dialog can be used to generate many variations at once, and the variations can be optionally compressed into a ZIP file for easy portability.

Spinning documents with whirl dialog

Normally when spinning a document, all spintax is resolved by randomly choosing phrases from the phrase sets. The "Whirl" dialog allows spintax to be kept and sentence variants to be turned into large blocks of spintax. These options are used when the variations are to be fed into third party applications that will resolve the spintax.

Here are a couple of document variations spun from the document.

A merry aged ghost was old King Cole.  And a jolly old spirit
was he.  He called for his bowl and pipe.  Then he yelled for his
three fiddlers.

Aged Tsar Cole was a merry old specter.  He was a merry aged soul.
He yelled for his pipe and bowl.  And he yelled for his fiddlers three.