Simple context-free grammar.

by Alina Kononov

Natural Language Generation

How to automatically generate your thesis.

Presentation Summary

In this presentation, I show a few simple methods for natural language generation, including Markov text generators, n-gram Markov models, and context-free grammar.

Examples

  • haiku.py: “Cut-up spoetry” or Haikus randomly generated from mass emails to UIUC engineering graduate students (emails.txt).
  • markov.tar: Implementation of a simple Markov text generator and an n-gram Markov text generator to rehash abstracts (abstrats.txt).
  • CFG.py: Implementation of a simple context-free grammar to generate grammatically correct sentences from a word bank (words.txt).

All natural language