{"id":1543,"date":"2022-09-24T21:55:22","date_gmt":"2022-09-24T21:55:22","guid":{"rendered":"http:\/\/www.wellformedness.com\/blog\/?p=1543"},"modified":"2022-10-01T15:27:17","modified_gmt":"2022-10-01T15:27:17","slug":"next-toolkit-2-electric-boogaloo","status":"publish","type":"post","link":"https:\/\/www.wellformedness.com\/blog\/next-toolkit-2-electric-boogaloo\/","title":{"rendered":"The next toolkit 2: electric boogaloo"},"content":{"rendered":"<p>I just got back from the excellent <a href=\"https:\/\/www.jeffreyheinz.net\/events\/WMTRPprogram.html\">Workshop on Model Theoretic Representations in Phonology<\/a>. While I am not exactly a member of the &#8220;Delaware school&#8221;, i.e., the model-theoretic phonology (MTP) crowd, I am a big fan. In my talk, I contrasted the model-theoretic approach to an approach I called the <em>black box <\/em>approach, using neural networks and program synthesis solvers as examples of the latter. I likened the two styles to <a href=\"https:\/\/en.wikipedia.org\/wiki\/Neats_and_scruffies\">neat vs. scruffy<\/a>, <a href=\"https:\/\/en.wikipedia.org\/wiki\/Worse_is_better\">better is better vs. worse is better<\/a>, rationalists vs. empiricists, and <a href=\"https:\/\/en.wikipedia.org\/wiki\/Cowboys_%26_Aliens\">cowboys vs. aliens<\/a>.<\/p>\r\n<p>One lesson I drew from this comparison is the need for MTPists to develop high-quality software\u2014the next toolkit 2. I didn&#8217;t say much during my talk about what I imagine this to be like, so I thought I&#8217;d leave my thoughts here. Several people\u2014Al\u00ebna Aks\u00ebnova, Hossep Dolatian, and Dakotah Lambert, for example\u2014have developed interesting MTP-oriented libraries. While I do not want to give short schrift to their work, I think there are two useful models for the the next next toolkit: (my own) Pynini and PyTorch. Here is what I see as the key features:<\/p>\r\n<ol>\r\n<li>They are ordinary Python on the front-end. Of course, both have a C++ back-end, and PyTorch has a rarely used C++\u00a0 API, but that&#8217;s purely a matter of performance; both have been slowly moving Python code into the C++ layer over the course of their development.The fact of the matter is that in 2022, just about anyone who can code at all can do so in Python.<\/li>\r\n<li>While both are devilishly complex, their design follows the principle of least suprise; there is only a bit of what Pythonistas call <em>exhuberant syntax<\/em> (Pynini&#8217;s use of the @ operator, PyTorch&#8217;s use of _ to denote in-place methods).<\/li>\r\n<li>They have extensive documentation (both in-module and up to book length).<\/li>\r\n<li>They have extensive test suites.<\/li>\r\n<li>They are properly packaged and can be installed via PyPi (i.e., via <tt>pip<\/tt>) or Conda-Forge (via <tt>conda<\/tt>).<\/li>\r\n<li>They have corporate backing.<\/li>\r\n<\/ol>\r\n<p>I understand that many in the MTP community are naturally\u2014constitutionally, even\u2014drawn to functional languages and literate programming. I think this should not be the initial focus. It should be ease of use, and for that it is hard to beat ordinary Python in 2022. Jupyter\/Colab support is a great idea, though, and might satisfy the literate programming itch too.<\/p>\r\n","protected":false},"excerpt":{"rendered":"<p>I just got back from the excellent Workshop on Model Theoretic Representations in Phonology. While I am not exactly a member of the &#8220;Delaware school&#8221;, i.e., the model-theoretic phonology (MTP) crowd, I am a big fan. In my talk, I contrasted the model-theoretic approach to an approach I called the black box approach, using neural &hellip; <a href=\"https:\/\/www.wellformedness.com\/blog\/next-toolkit-2-electric-boogaloo\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;The next toolkit 2: electric boogaloo&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_crdt_document":"","footnotes":""},"categories":[3,4,5,6,8],"tags":[],"class_list":["post-1543","post","type-post","status-publish","format-standard","hentry","category-dev","category-language","category-nlp","category-phonology","category-python"],"_links":{"self":[{"href":"https:\/\/www.wellformedness.com\/blog\/wp-json\/wp\/v2\/posts\/1543","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wellformedness.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wellformedness.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wellformedness.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wellformedness.com\/blog\/wp-json\/wp\/v2\/comments?post=1543"}],"version-history":[{"count":4,"href":"https:\/\/www.wellformedness.com\/blog\/wp-json\/wp\/v2\/posts\/1543\/revisions"}],"predecessor-version":[{"id":1583,"href":"https:\/\/www.wellformedness.com\/blog\/wp-json\/wp\/v2\/posts\/1543\/revisions\/1583"}],"wp:attachment":[{"href":"https:\/\/www.wellformedness.com\/blog\/wp-json\/wp\/v2\/media?parent=1543"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wellformedness.com\/blog\/wp-json\/wp\/v2\/categories?post=1543"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wellformedness.com\/blog\/wp-json\/wp\/v2\/tags?post=1543"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}