Chapter 2. Using Sam

Sam provides a graphical interface that is divided into five areas.

Main window

The order of the tabs represents a complete Sam workflow from creating a model to testing it.

Input & output files

Define what files to work on. You can save and load this configuration by using the Save and Load buttons respectively.

Warning

The Save and Load menus only save the paths and options defined here. They don't save the associated files!

Here you also have the option to select between supported model compilation / test backends. Depending on your Simon installation, not all might be available.

Input & output selection

If you want to compile and / or test the Simon model, you can use the Modify Simon's model option to load the appropriate files. Both scenarios and prompts will be serialized as appropriate.

When Simon compiles the model, it will automatically remove untrained words during serialization as well as adapting the prompts appropriately. This will also happen when selecting Modify Simon's model. If you do, however serialize them separately using Serialize scenarios and Serialize prompts this adaption will not be performed and you alone are responsible for the validity of the input files. If you provide file names directly this of course applies even more so.

When selecting a static model as the used model type Sam will still compile the language model, just like Simon would. It also copies the given base model input files to the output paths.

Sam allows the user to provide different types of prompts files for the creation and the testing of the model. For more information about how to use this feature effectively, please refer to the section on effective testing.

Test configuration

Users can set up an arbitrary number of test configurations to compare different model parameters. All configured tests will be run and all are listed in any reports that might be exported. Through the option of supplying different input files than the compiled model, reference models (baselines) can be included in the report.

Since Simon 0.4, the primary file format for models is the newly introduced SBM format. While Sam will also create SBM models, the testing still requires low level input files. This may seem counter intuitive but presents certain advantages in practice: The Simon model compilation (and thus also the SAM model compilation) still builds the low level output files for both SPHINX and HTK model compilers before packaging them into SBMs so pointing SAM to these (temporary) files is not difficult and in fact the default when using Modify Simon's model. Because acoustic model compilation is typically an iterative process, the compiler typically produces multiple temporary versions of different stages of parameter estimation. By allowing low level input, testing and comparing these intermediate results is much easier.

If you want to test a model you received as a SBM container, you can extract it with SAM through the Extract Simon Model option to gain access to the low level input files required for testing with Sam.