Overview

In this project, I developed an interactive Shiny application, MaxEnt with Hidden Structure in R, designed to assist linguists in generating phonological grammars (weights) using a Maximum Entropy model. The app was built based on the existing HGR model developed by Staubs (2014). HGR finds solutions for learning problems (with or without hidden structure), generate distributions over forms, and performs online learning simulations.

You can access the Shiny app here.

User Guide

Input File Format

  • The input file should be a CSV or TXT file with the following columns:
    • input: Input forms
    • output: Output forms
    • probability: Observed probabilities or raw frequencies
    • Additional columns representing various constraints.

Using the Shiny App

  1. Upload your data file: Use the "Choose Input File" button to upload your CSV or TXT file.
  2. Select input type: Choose between "Probabilities" and "Raw Frequencies".
  3. Select prior type: Choose between "L2" and "L1".
  4. Generate Grammar: Click "Generate Grammar" to produce the grammar.
  5. Edit constraint weights: If needed, adjust weights in the dynamic UI and click "Update Grammar" to recalculate probabilities and errors.
  6. Download outputs: Use the "Download Output" button to save the generated tableau.

Sample Input Files

The Shiny app includes three sample input files, which you can download from here. These files demonstrate different scenarios for using the MaxEnt model, including cases with or without hidden structures and cases of having output candidates with raw frequencies instead of normalized probabilities. These sample files can be uploaded directly into the Shiny app to see how the app handles different types of data.

Citations

Acknowledgments

This research was supported by the National Science Foundation grant BCS-2140826 to the University of Massachusetts Amherst.