Upgrade to Pro — share decks privately, control downloads, hide ads and more …

> GET FLASK! - Hacking phones to make voice- ac...

> GET FLASK! - Hacking phones to make voice- activated text adventure games

A lightning talk about creating a telephony port of the adventure game "Thy Dungeonman", of Homestar Runner fame, using Sinatra and the Tropo API.

Mattt Thompson

September 22, 2011
Tweet

More Decks by Mattt Thompson

Other Decks in Programming

Transcript

  1. > GET FLASK Hacking phones to make voice- activated text

    adventure games Mattt Thompson (@mattt) Lone Star Ruby Conf V
  2. { "ask": { "choices": Object, "allowSignals": String or Array, "attempts":

    Integer, "bargein": Boolean, "minConfidence": Integer, "name": String, "recognizer": String, "required": Boolean, "say": Object, "timeout": Float, "voice": String } }
  3. on

  4. <rule id="ROOT" scope="public"> <item> <item> <ruleref uri="#PREDICATE"/> <tag>out.predicateSlot=rules.PREDICATE.predicateSubslot;</tag> </item> <item>

    <ruleref uri="#OBJECT"/> <tag>out.objectSlot=rules.OBJECT.objectSubslot;</tag> </item> <tag>out.v=out.predicateSlot + out.objectSlot;</tag> </item> </rule>
  5. <rule id="PREDICATE" scope="public"> <tag>out.predicateSubslot="look"; out.objectSlot="";</tag> ... <one-of> <item> <one-of> <item>get</item>

    <item>take</item> <item>get ye</item> <item>take ye</item> <item>get yon</item> <item>take yon</item> </one-of> <tag>out.predicateSubslot="get ";</tag> </item> </one-of> </rule>
  6. <rule id="OBJECT" scope="public"> <one-of> <item> north <tag>out.objectSubslot="north";</tag> </item> <item> south

    <tag>out.objectSubslot="south";</tag> </item> <item> dennis <tag>out.objectSubslot="dennis";</tag> </item> <item> not dennis <tag>out.objectSubslot="not dennis";</tag> </item> </one-of> </rule>