Abramsky and Sadrzadeh (2014): Semantic Unification: A Sheaf Theoretic Approach to Natural Language #
Abramsky and Sadrzadeh model basic discourse representation structures as a presheaf on
contexts, finite vocabularies of relation symbols with finite sets of variables
(DRT.presheaf), and read anaphora resolution as gluing: the local theories of a discourse's
parts glue along a cover, a choice of which referents to identify, when some global theory
restricts to each of them.
Proposition 1 claims that a gluing is unique when it exists. The paper's own second example
refutes it: John(b) is invisible to every restriction, so it can be added to the listed gluing
(isGluing_beats_insert). Gluings are unique exactly along covers jointly surjective on
literals (DRT.isSeparatedFor_iff), the covers of the Grothendieck topology the paper asks for
but leaves aside, for which basic DRSs form a sheaf (DRT.isSheaf_literalCoverage). The proof of
Proposition 1 builds the right candidate, the least gluing (DRT.Cover.exists_isGluing_iff): the
discussion example fails because the candidate does not restrict back, Example 3's merged cover
because it is inconsistent. The discussion's claim that disjoint vocabularies leave consistency
as the only obstruction needs injective cover maps (not_forall_exists_isGluing_of_disjoint), and
Example 3's vocabularies are not disjoint: Man occurs in two parts.
The probabilistic half composes the presheaf with a distribution functor. A distribution glues a
family of point masses iff it is carried by the deterministic gluings
(map_restrict_eq_dirac_iff), so the several multivalued gluings of §5.1 are mixtures of
deterministic ones. In the bananas discourse the corpus frequencies weight the coverings, and the
image of that distribution along the gluing map ranks ripe bananas, cheeky monkeys first
(gluingMeasure_le).
Main statements #
not_isSeparatedFor_beats: Proposition 1 fails on Example 2.not_forall_exists_isGluing_of_disjoint: disjoint vocabularies and a consistent candidate do not make a gluing.map_restrict_eq_dirac_iff: the multivalued gluings of point masses.gluingMeasure_le,gluingProbability_rounds_iff: the most likely resolution, and the printed distribution rounds the computed one except ford(t₄) = 0.205, which is10/48 ≈ 0.208.
Implementation notes #
Varis the paper's variable names; the substrate's sheaf theorem assumes infinitely many.D_Ris formalised for probabilities, as image measures (Measure.map), not over an arbitrary semiring.- The corpus frequencies and the printed probabilities are read from
Data.Experiments.AbramskySadrzadeh2014.
References #
The paper's examples #
Rel n lists the n-ary relation symbols of the paper's examples.
- R : Rel 1
- S : Rel 1
- john : Rel 1
- man : Rel 1
- sleeps : Rel 1
- snores : Rel 1
- donkey : Rel 1
- grey : Rel 1
- cup : Rel 1
- plate : Rel 1
- banana : Rel 1
- monkey : Rel 1
- ripe : Rel 1
- cheeky : Rel 1
- owns : Rel 2
- beats : Rel 2
- broke : Rel 2
- putOn : Rel 3
- gave : Rel 3
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
lang is the relational language of the examples.
Equations
- AbramskySadrzadeh2014.lang = { Functions := fun (x : ℕ) => Empty, Relations := AbramskySadrzadeh2014.Rel }
Instances For
Equations
- AbramskySadrzadeh2014.instDecidableEqVar x✝ y✝ = if h : x✝.ctorIdx = y✝.ctorIdx then isTrue ⋯ else isFalse ⋯
lit A x̄ is the literal A(x̄), and lit A x̄ false is ¬A(x̄).
Equations
- AbramskySadrzadeh2014.lit r args pos hr h = { rel := ⟨⟨n, r⟩, hr⟩, args := fun (i : Fin (↑⟨⟨n, r⟩, hr⟩).fst) => ⟨args i, ⋯⟩, pos := pos }
Instances For
hom f is the context morphism acting as f on variables.
Equations
- AbramskySadrzadeh2014.hom f hf hL = { incl := hL, map := fun (t : ↥c.vars) => ⟨f ↑t, ⋯⟩ }
Instances For
Example 1: John sleeps. He snores. (Examples.ex1) #
The first example glues over this context.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The cover {x} ↦ z ↤ {y} merges he with John.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The local sections are s₁ = {John(x), sleeps(x)} and s₂ = {snores(y)}.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The gluing is s = {John(z), sleeps(z), snores(z)}.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Every literal over {z} renames a literal of a part, so the gluing is unique.
Example 2: John beats his donkey. (Examples.ex2) #
The second example glues over this context.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The local sections are s₁ = {John(x)}, s₂ = {donkey(y)} and
s₃ = {owns(u, v), beats(u, v)}.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The paper's gluing is s = {John(a), donkey(b), owns(a, b), beats(a, b)}.
Equations
- One or more equations did not get rendered due to their size.
Instances For
s ∪ {John(b)} is a second gluing, since John(b) renames no literal of a part and adding
it changes no restriction.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Proposition 1 fails for Example 2, whose cover is not jointly surjective on literals.
Example 3: John owns a donkey. It is grey. (Examples.ex3) #
The third example glues over this context.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The third example has these covering contexts; Man occurs in the first two.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The local sections are s₁ = {John(x), Man(x)}, s₂ = {donkey(y), ¬Man(y)} and
s₃ = {grey(z)}.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Merging x and y makes the candidate hold Man and ¬Man of one referent.
The gluing is s = {John(a), Man(a), donkey(b), ¬Man(b), grey(b)}.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The two covers give Example 3's readings, it as the donkey and not as John.
Example 4: John put the cup on the plate. He broke it. (Examples.ex4) #
The fourth example glues over this context.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The fourth example has these covering contexts.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The local sections are s₁ = {John(x), Cup(y), Plate(z), PutOn(x, y, z)} and
s₂ = {Broke(u, v)}.
Equations
- One or more equations did not get rendered due to their size.
Instances For
It has two plausible antecedents.
Instances For
Equations
- AbramskySadrzadeh2014.instDecidableEqBroken x✝ y✝ = if h : x✝.ctorIdx = y✝.ctorIdx then isTrue ⋯ else isFalse ⋯
Equations
- One or more equations did not get rendered due to their size.
Each antecedent has a referent.
Equations
Instances For
The gluing is {John(x), Cup(y), Plate(z), PutOn(x, y, z), Broke(x, ·)}, with the chosen
antecedent.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Either choice of antecedent yields a gluing.
Both readings of Example 4 glue.
The discussion example: overlapping vocabularies #
The discussion example glues over this context.
Equations
- AbramskySadrzadeh2014.overlapCtx = { vocab := {⟨1, AbramskySadrzadeh2014.Rel.R⟩, ⟨1, AbramskySadrzadeh2014.Rel.S⟩}, vars := {AbramskySadrzadeh2014.Var.z, AbramskySadrzadeh2014.Var.w} }
Instances For
The local sections are s₁ = {R(x), S(u)} and s₂ = {S(y), R(v)}.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The sections do not glue, since the candidate {R(z), S(w), S(z), R(w)} restricts along the
first map to {R(x), S(x), R(u), S(u)} ≠ s₁.
The local section is s₁ = {R(x)}.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Pairwise disjoint vocabularies and a consistent candidate do not make a gluing, against the
discussion of Proposition 1: the candidate {R(z)} of the one-part cover {x, u} ↦ {z}
restricts to {R(x), R(u)}. Injective cover maps suffice (DRT.Cover.isGluing_glue).
Multivalued gluing #
Equations
A probability measure on global theories glues the point masses δ_{sᵢ} in D ∘ F iff it
is carried by the gluings of the sᵢ.
Probabilistic anaphora: *John gave the bananas to the monkeys. They were ripe. They were #
cheeky.* (Examples.bananas)
The bananas discourse glues over this context.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The bananas discourse has these covering contexts.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The local sections are s₁ = {John(x), Banana(y), Monkey(z), Gave(x, y, z)},
s₂ = {Ripe(u)} and s₃ = {Cheeky(v)}.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Each antecedent has a referent.
Equations
Instances For
The covering c induces the candidate global section t_c.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The score of a covering sums the corpus frequencies of its two mergings.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The distribution over coverings weights each by its score, normalised.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The paper's d ∈ D_R F(L, X) is the image of the covering distribution along c ↦ t_c.
Equations
- AbramskySadrzadeh2014.gluingMeasure = MeasureTheory.Measure.map AbramskySadrzadeh2014.ripeGluing AbramskySadrzadeh2014.coveringMeasure
Instances For
Ripe bananas, cheeky monkeys (t₂) is the most likely resolution, with probability 1/2.
The printed d(t_c) is score c / 48 rounded, except d(t₄) = 0.205 for 10/48.