In the Rational Speech Acts framework, the literal meaning of an utterance can depend on semantic free variables—an adjective’s threshold, a comparison class, a quantifier’s scope, or the lexicon itself—and listeners resolve these variables jointly with the world state by reasoning pragmatically about speakers. Runnable WebPPL implementations are in the Probabilistic Language Understanding web book: