Applicative Abstract Categorial Grammar
We present the grammar/semantic formalism of Applicative AbstractCategorial Grammar (AACG), based on the recent techniques fromfunctional programming: applicative functors, staged languages andtyped final language embeddings. AACG is a generalization ofAbstract Categorial Grammars (ACG), retaining the benefits of ACG as agrammar formalism and making it possible and convenient to express avariety of semantic theories.We use the AACG formalism to uniformly formulate Potts' analyses ofexpressives, the dynamic-logic account of anaphora, and thecontinuation tower treatment of quantifier strength, quantifierambiguity and scope islands. Carrying out these analyses in ACGrequired compromises and the ballooning of parsing complexity, or wasnot possible at all. The AACG formalism brings modularity, which comesfrom the compositionality of applicative functors, in contrast tomonads, and the extensibility of the typed final embedding. Theseparately developed analyses of expressives and QNP are used as theyare to compute truth conditions of sentences with both these features.AACG is implemented as a `semantic calculator', which is the ordinaryHaskell interpreter. The calculator lets us interactively writegrammar derivations in a linguist-readable form and see their yields,inferred types and computed truth conditions. We easily extendfragments with more lexical items and operators, and experiment withdifferent semantic-mapping assemblies. The mechanization lets asemanticist test more and more complex examples, making empirical testsof a semantic theory more extensive, organized and systematic.