Tag: parsing

  1. Parsing User Input with Python, any% Speedrun

    21 October 2022

    Over the summer of 2022.ev, scholar.social (a node of the Fediverse that has cultivated a community of teachers, instructors, librarians, and academics of all stripes) held their biannual online conference called Summer School (Winter School, of course, is the other one). Summer/Winter School is described as an interdisciplinary online conference where denizens of the Fediverse could present their work and hold classes, predicated upon the belief that knowledge should be free and accessible to everyone. I finally heard about this year's conference before the fact and, as luck would have it I had a proposal for a …

    Read more...

  2. Parsing simple commands in Python.

    07 February 2017

    A couple of weeks ago I ran into some of the functional limits of my web search bot, a bot that I wrote for my exocortex which accepts English-like commands ("Send me top 15 hits for HAL 9000 quotes.") and runs web searches in response using the Searx meta-search engine on the back end.  This is to say that I gave my bot a broken command ("Send hits for HAL 9000 quotes.") and the parser got into a state where it couldn't cope, threw an exception, and crashed.  To be fair, my command parser was very brittle and it was …

    Read more...