Algorithmcore
Gale-Church alignment
Also called length-based sentence alignment.
Align sentences by dynamic programming with a cost from a Gaussian model of the ratio of character lengths of matched sentences.
- Solves
- Sentence alignment
- Time
- Θ(I J) worst
- Space
- Θ(I J) extra
- Where
- I = the number of sentences of the first text; J = the number of sentences of the second text
- Model
- Word RAM
- Properties
- deterministicexactofflineiterative
- Evidence
- Proof sketchCode in 1 languages
- Origin
- William A. Gale, Kenneth W. Church, 1991
Gale-Church alignment solves sentence alignment for a parallel corpus with sentence lengths in characters only. It is a dynamic program over the pairs (sentences used in text 1, sentences used in text 2). Each step adds a bead of type 1-1, 1-0, 0-1, 2-1, 1-2 or 2-2, and the cost of a bead is of its prior times the probability of its length difference under a Gaussian model. The result is the cheapest monotone alignment in time. Gale and Church (1993) found that it aligns about 96% of the sentences of their trilingual test set correctly. That figure is a measurement, not a guarantee.
In plain words
A text and its translation have about the same number of sentences in the same order. Some sentences are split in two, some are merged, and a few are missing on one side. Long sentences tend to have long translations, and short ones short.
The method uses only the length of each sentence in characters. For a candidate pairing it asks two questions: how common is this kind of pairing (one with one, two with one, one with nothing), and how well do the lengths agree? Each answer gives a penalty. The method then walks through both texts together, as in edit distance, and keeps for each position the cheapest way to reach it. At the end it follows the stored choices back to get the pairs.
It needs no dictionary and no knowledge of the languages, and it is fast.
The problem
The input is the lengths of the sentences of text 1 and of text 2, in characters. A bead of type - joins consecutive sentences of text 1 with consecutive sentences of text 2. An alignment is a sequence of beads that covers both texts in order, each sentence in exactly one bead. The types are , as in Gale and Church (1993). The task is to find an alignment of the least total cost, where the cost of a bead with and characters is
Here is the standard normal distribution function, so is the two-sided tail of the Q function. The model behind it says that each character of text 1 gives a random number of characters of text 2, independently, with mean and variance . Then is about normal with variance . Section 4 of the paper writes
The C program in the appendix uses the mean of the two lengths in place of : and . The sign does not matter, because only is used. The program form is symmetric in the two texts and is defined for a 0-1 bead, where and the text form divides by zero. This page and its code use the program form.
The constants are those of the paper. The value (they measured 1.1 for German to English and 1.06 for French to English, in characters) and (they measured 7.3 and 5.6). The priors come from 1312 hand-aligned beads (Table 5): 1-1 0.89, "1-0 or 0-1" 0.0099, "2-1 or 1-2" 0.089, 2-2 0.011. The program uses the value of each two-way category for both directions, so the six weights sum to 1.0988, not to 1. The constants and the priors are estimates from their data, so the cost is a heuristic model, not a property of translation.
The algorithm
is the least cost of an alignment of the first sentences of text 1 with the first sentences of text 2, and is the type of its last bead. Every cell starts at .
GALE-CHURCH(x_1 .. x_I, y_1 .. y_J) ▷ costs in nats- 1
D(0, 0) ← 0 - 2
for i ← 0 to I do - 3
for j ← 0 to J do - 4
if (i, j) = (0, 0) then continue - 5
for each type (p, q) in 1-1, 1-0, 0-1, 2-1, 1-2, 2-2 with p ≤ i and q ≤ j do - 6
d ← D(i - p, j - q) + COST(x_{i-p+1} + .. + x_i, y_{j-q+1} + .. + y_j, p, q) - 7
if d < D(i, j) then D(i, j) ← d; B(i, j) ← (p, q) - 8
(i, j) ← (I, J) - 9
while (i, j) ≠ (0, 0) do - 10
(p, q) ← B(i, j); output the bead (i - p + 1 .. i, j - q + 1 .. j); (i, j) ← (i - p, j - q) - 11
return the beads in reverse order and D(I, J) COST(l_1, l_2, p, q)- 12
l̄ ← (l_1 + l_2 / c) / 2 - 13
δ ← (l_2 - c l_1) / sqrt(s² l̄) - 14
return -ln Prior(p, q) - ln(2 (1 - Φ(|δ|)))
Lines L2 and L3 visit the cells in row-major order. Each type at line L5 points to a cell that comes earlier in this order, so its value is final when line L6 reads it. Line L6 adds the cost of the last bead to the best cost of the rest, as in edit distance with three more kinds of step. Line L7 keeps the minimum and its type. Lines L8 to L10 are the traceback. The lengths of line L6 come from prefix sums, so each candidate costs .
Tie rule. Line L7 replaces only on a strict decrease, so among the types that reach the minimum at a cell it keeps the first in the order of line L5.
Paragraphs first. Gale and Church run the same program twice. It first aligns paragraphs (with the paragraph lengths), and then aligns the sentences inside each pair of aligned paragraphs. This keeps and small and keeps an error from spreading beyond one paragraph.
Far tails. For above about 38, rounds to 1 in double precision and appears. The implementation switches to the asymptotic form for , so every bead has a finite cost. The C program returns a fixed large cost instead.
Example
Text 1 has 5 sentences of 62, 31, 44, 18 and 70 characters, and text 2 has 4 sentences of 66, 80, 21 and 72 characters. With and , the table gives and the type stored in , rounded to two decimals.
| \ | 0 | 1 | 2 | 3 | 4 |
|---|---|---|---|---|---|
| 0 | 0 | 16.08 (0-1) | 34.30 (0-1) | 43.26 (0-1) | 60.26 (0-1) |
| 1 | 15.46 (1-0) | 0.28 (1-1) | 8.87 (1-2) | 17.83 (0-1) | 34.83 (0-1) |
| 2 | 26.05 (1-0) | 3.82 (2-1) | 4.85 (1-1) | 9.66 (1-2) | 17.26 (1-2) |
| 3 | 38.71 (1-0) | 16.48 (1-0) | 2.89 (2-1) | 6.04 (2-2) | 11.03 (1-2) |
| 4 | 47.17 (1-0) | 24.94 (1-0) | 7.13 (2-1) | 3.24 (1-1) | 11.09 (2-2) |
| 5 | 63.86 (1-0) | 41.63 (1-0) | 19.20 (2-1) | 12.48 (1-1) | 3.43 (1-1) |
The traceback from reads 1-1, 1-1, 2-1, 1-1. So the alignment is (62 | 66), (31 + 44 | 80), (18 | 21), (70 | 72), with bead costs 0.2815, 2.6084, 0.3466 and 0.1918, and the total is 3.4283. For the 2-1 bead, , , and . Most of its cost is the prior: , against for a 1-1 bead. A bead of one sentence with nothing (1-0 or 0-1) costs at least , plus a large length term, which is why the first row and the first column are so expensive.
A second case shows a merge. With lengths 40, 25, 30, 62, 12 against 43, 58, 65, the last sentence of 12 characters does not become a 1-0 bead. It joins 62 in a 2-1 bead (74 against 65), which is cheaper.
Correctness
The claim is that the output is a monotone alignment of the least total cost with the six types. A path from cell to whose steps are bead types is the same thing as such an alignment. The invariant is that when cell has been visited, is the least cost of a path to it: the last step of the best path is some type , and the rest is a best path to , which is the principle of optimality. The proof is an induction over the cells in row-major order, and the traceback then rebuilds a path of cost . The full proof is in the proofs file.
The claim is exact for the cost model. Whether the cheapest alignment is the right one is a question about the model, and the answer is only measured.
Proof: The Gale-Church dynamic program returns a cheapest monotone bead alignmentfull
Fix the sentence lengths and , the bead types and the bead cost of lines L12 to L14. Every value of cost is a real number: the prior is positive, and is finite for every real (the implementation uses an asymptotic form where erfc underflows).
A path to the cell is a sequence of cells with for each . Step is the bead that joins the sentences with . A path to is exactly a monotone alignment in which each sentence is in one bead: the beads cover the positions and in order and without overlap, because the indices only grow and every step moves by its bead size. The cost of a path is the sum of the costs of its steps, with and the same for . Let be the minimum cost of a path to , or if there is no path.
Every step of has , so a path to has at most steps and the set of paths to a cell is finite. The minimum exists when the set is not empty.
Lemma 1 (recurrence). , and for ,
with and .
Proof. The only path to is the empty one, of cost 0: a non-empty path ends at a cell with . For , a path to is non-empty, and its last step is some with and . Removing the last step leaves a path to , and its cost drops by the cost of that bead, which depends only on and . Conversely, appending the step to any path to gives a path to . So the paths to with last step are in bijection with the paths to , and their costs differ by the same constant. The minimum over all paths is the minimum over of the minimum over each class.
Lemma 2 (the table). When the loops of lines L2 and L3 end, for every cell, and if and , then is a bead type that reaches the minimum of Lemma 1.
Proof. The loops visit the cells in row-major order. For each , the cell comes before in this order: either and its row is smaller, or , and it is the cell before in the same row. We use induction over the order of the visits. Line L1 sets , and line L4 never changes it. At a cell , by the induction hypothesis every predecessor already holds and is not changed later, because each cell is written only on its own visit. Line L6 computes each candidate of Lemma 1 for the predecessors with a finite value; the others give and are skipped, which does not change a minimum. Line L7 keeps the smallest candidate seen so far, starting from , and stores its bead type. After line L5 has run through , is the minimum of Lemma 1, which is , and is a bead type that reaches it: the first one in the order of , because line L7 replaces only on a strict decrease.
Theorem. For all , GALE-CHURCH returns a list of beads that is a monotone alignment of the two texts, of cost , the minimum over all monotone alignments with the six bead types, and returns .
Proof. A path to always exists, for example beads of type 1-0 and then beads of type 0-1. So . By induction along the paths, every cell on a path of finite cost has a finite value. The traceback of lines L8 to L10 starts at . We claim that while is the current cell, and the beads output so far, read in reverse, have cost . This holds at the start. If it holds at , Lemma 2 gives with , where is the cost of the bead just output. So , and the beads output now have cost . Each step lowers by at least 1, so the loop ends, and it ends at because and never become negative ( and by line L5). At the end the beads have cost . Read in reverse, the cells visited form a path from to , so by the remark on paths the beads are a monotone alignment. Line L11 returns them and .
Remark (the tie rule). If two bead types give the same value at a cell, line L7 keeps the first one in the order 1-1, 1-0, 0-1, 2-1, 1-2, 2-2. The theorem does not depend on this choice. The tests compare the cost of the output with the minimum over all paths listed one by one, and they check that the output is a path.
Remark (complexity). Each of the cells looks at most at 6 predecessors, and with prefix sums each candidate costs operations, so lines L1 to L7 take time. The table and the back pointers take space, and the traceback has at most steps.
Complexity
In the word RAM model, with the lengths and the costs as machine numbers, there are cells and each looks at most at 6 types. With prefix sums, each candidate of line L6 costs , including one call of erfc. So the time is in every case. The table and the back pointers take space. Without the back pointers, the last three rows of (the 2-1 and 2-2 types reach two rows back) give the cost in space, but not the alignment.
In practice the cost is small because the paragraphs are aligned first, so and are the numbers of sentences in one paragraph. A band around the diagonal, as in banded alignment, also cuts the work to for a band of width , but it is no longer exact if the best path leaves the band.
Properties
- Exact for its cost. It finds a cheapest alignment under the stated cost. It is not exact for the true alignment.
- Language independent. It uses no words, only lengths, so it works for any pair of languages whose lengths correlate. The constants and depend weakly on the pair.
- Monotone. It cannot find crossing beads. A sentence moved to another place in the translation becomes a 1-0 and a 0-1 bead, or a wrong pair.
- Local errors. An error tends to stay in a few beads, because the path rejoins the right diagonal after a short run.
- A confidence for free. The cost of each bead is a score. Gale and Church kept the best 80% of the beads by this score, and the error rate on the rest fell from 4% to 0.7% (a measurement).
Variants and improvements
- Lengths in words. Brown, Lai and Mercer (1991) used the same kind of dynamic program with sentence lengths in words, on the Canadian Hansards. Gale and Church argue that lengths in characters work better on their data.
- Lexical cues. Later methods add a score from a bilingual lexicon or from cognates (words with the same spelling), which helps where the lengths do not decide. These are no longer purely length-based.
- Other bead sets. Some implementations add 3-1 and 1-3 beads. The dynamic program changes only in line L5.
- Linear space. The divide and conquer method of Hirschberg gives the alignment in space with about twice the time, as for any dynamic program of this shape.
When to use it
Use Gale-Church as the first step to build a parallel corpus from documents that are already paired, with paragraphs that mostly correspond and few omissions. It is fast and needs no resources, so it scales to corpora like the Canadian Hansards. When large parts are missing or reordered, or when the two languages have very different sentence lengths, use a method with lexical anchors. Before word alignment, filter out the beads with the highest cost.
Pitfalls
- The text form of . With at line L13, a 0-1 bead has and the cost is undefined. Use the mean length of line L12, as the C program does.
- at line L14. For a large , rounds to 0 and the cost becomes . Then all candidates of a cell can tie at and the traceback can break. Use an asymptotic form or a clamp.
- The order of the loops. Line L6 reads . If the loops run in an order in which that cell is not final, the result is wrong. Row-major order works for all six types.
- No paragraph step. On a long document with no paragraph alignment, the table has cells and one omission early on can shift many beads. Align paragraphs first, or use anchors.
- Normalized priors. Dividing the six weights by 1.0988 adds to the cost of every bead at line L14. An alignment with more beads then pays more, so the result can differ from the paper's program. State which form you use.
Implementations
Each implementation follows the pseudocode above. A comment @line links a line of code to a line of the pseudocode. Point at a line of the pseudocode to see the matching code. The build runs the native tests of each language.
# SPDX-License-Identifier: MIT
# Part of https://algorithm.tamnd.com/gale-church-alignment/. The authors are listed in prov/TXM3A8.jsonl.
"""Gale-Church sentence alignment by sentence lengths in characters.
The input is two lists of sentence lengths, x (language L1) and y (language L2).
The output is a list of beads. A bead (i0, i1, j0, j1) joins the L1 sentences
i0+1 .. i1 with the L2 sentences j0+1 .. j1 (fencepost indices, 0 at the left
edge). The bead types are the six of Gale and Church (1993): 1-1, 1-0, 0-1,
2-1, 1-2 and 2-2.
The cost of a bead is -log(Prior(p, q) * 2 * (1 - Phi(|delta|))) in nats, with
delta = (l2 - c * l1) / sqrt(s2 * lbar) and lbar = (l1 + l2 / c) / 2, as in the
C program in the appendix of the paper. The text of the paper writes l1 in
place of lbar; that form is undefined for a 0-1 bead, where l1 = 0.
The dynamic program works in the tropical semiring (min, +) on these costs.
Tie rule: line L7 keeps the first bead type in the order of BEADS that reaches
the minimum.
"""
import math
from typing import Dict, List, Sequence, Tuple
INF = float("inf")
# The order of the bead types fixes the tie rule.
BEADS: Tuple[Tuple[int, int], ...] = ((1, 1), (1, 0), (0, 1), (2, 1), (1, 2), (2, 2))
# Table 5 of Gale and Church (1993). The category "1-0 or 0-1" (0.0099) and the
# category "2-1 or 1-2" (0.089) are used for each direction, as the C program
# does, so the six weights sum to 1.0988, not to 1.
PRIORS: Dict[Tuple[int, int], float] = {
(1, 1): 0.89,
(1, 0): 0.0099,
(0, 1): 0.0099,
(2, 1): 0.089,
(1, 2): 0.089,
(2, 2): 0.011,
}
C_MEAN = 1.0 # c: expected characters of L2 per character of L1
S2_VAR = 6.8 # s^2: variance of the characters of L2 per character of L1
def log_two_sided_tail(x: float) -> float:
"""Return log(2 * (1 - Phi(|x|))) = log P(|Z| >= |x|) for a standard normal Z.
For |x| < 30 this uses math.erfc. Beyond, erfc is close to underflow, so it
uses the asymptotic series sqrt(2 / pi) exp(-x^2 / 2) / x * (1 - 1/x^2 + 3/x^4),
whose relative error there is below 1e-8. Cost O(1).
"""
x = abs(x)
if x < 30.0:
return math.log(math.erfc(x / math.sqrt(2.0)))
series = 1.0 - 1.0 / x**2 + 3.0 / x**4
return 0.5 * math.log(2.0 / math.pi) - 0.5 * x * x - math.log(x) + math.log(series)
def delta(l1: float, l2: float, c: float = C_MEAN, s2: float = S2_VAR) -> float:
"""The normalized length difference of a bead with l1 and l2 characters."""
lbar = (l1 + l2 / c) / 2.0 # @line L12
if lbar == 0:
return 0.0
return (l2 - c * l1) / math.sqrt(s2 * lbar) # @line L13
def bead_cost(l1: float, l2: float, p: int, q: int, c: float = C_MEAN, s2: float = S2_VAR,
priors: Dict[Tuple[int, int], float] = PRIORS) -> float:
"""Return -log(Prior(p, q)) - log(2 (1 - Phi(|delta|))) in nats."""
d = delta(l1, l2, c, s2)
return -math.log(priors[(p, q)]) - log_two_sided_tail(d) # @line L14
def align(x: Sequence[int], y: Sequence[int], c: float = C_MEAN, s2: float = S2_VAR,
priors: Dict[Tuple[int, int], float] = PRIORS) -> Tuple[List[Tuple[int, int, int, int]], float]:
"""Return (beads, total cost) of the cheapest monotone alignment of x with y.
x and y are lists of non-negative sentence lengths. Every sentence is in
exactly one bead, and the beads keep the order of both texts. Cost:
O(I J) time and O(I J) memory for the table and the back pointers, with
I = len(x) and J = len(y).
"""
nx, ny = len(x), len(y)
px = [0] * (nx + 1)
for i, v in enumerate(x):
px[i + 1] = px[i] + v
py = [0] * (ny + 1)
for j, v in enumerate(y):
py[j + 1] = py[j] + v
D = [[INF] * (ny + 1) for _ in range(nx + 1)]
B: List[List[Tuple[int, int]]] = [[(0, 0)] * (ny + 1) for _ in range(nx + 1)]
D[0][0] = 0.0 # @line L1
for i in range(nx + 1): # @line L2
for j in range(ny + 1): # @line L3
if i == 0 and j == 0: # @line L4
continue
for p, q in BEADS: # @line L5
if p > i or q > j or D[i - p][j - q] == INF:
continue
l1 = px[i] - px[i - p]
l2 = py[j] - py[j - q]
cost = D[i - p][j - q] + bead_cost(l1, l2, p, q, c, s2, priors) # @line L6
if cost < D[i][j]: # @line L7
D[i][j] = cost
B[i][j] = (p, q)
beads: List[Tuple[int, int, int, int]] = []
i, j = nx, ny # @line L8
while (i, j) != (0, 0): # @line L9
p, q = B[i][j] # @line L10
beads.append((i - p, i, j - q, j))
i, j = i - p, j - q
beads.reverse()
return beads, D[nx][ny] # @line L11
def alignment_cost(x: Sequence[int], y: Sequence[int], beads: Sequence[Tuple[int, int, int, int]],
c: float = C_MEAN, s2: float = S2_VAR,
priors: Dict[Tuple[int, int], float] = PRIORS) -> float:
"""The total cost of a given list of beads (for tests and for the reader)."""
total = 0.0
for i0, i1, j0, j1 in beads:
total += bead_cost(sum(x[i0:i1]), sum(y[j0:j1]), i1 - i0, j1 - j0, c, s2, priors)
return total
test_gale_church_alignment.py 99 lines
# SPDX-License-Identifier: MIT
# Part of https://algorithm.tamnd.com/gale-church-alignment/. The authors are listed in prov/TXM3A8.jsonl.
import math
import random
from gale_church_alignment import (
BEADS,
PRIORS,
align,
alignment_cost,
bead_cost,
delta,
log_two_sided_tail,
)
X = [62, 31, 44, 18, 70]
Y = [66, 80, 21, 72]
def all_alignments(nx, ny):
"""Every monotone sequence of beads from (0, 0) to (nx, ny)."""
if nx == 0 and ny == 0:
yield []
return
for p, q in BEADS:
if p <= nx and q <= ny:
for rest in all_alignments(nx - p, ny - q):
yield rest + [(nx - p, nx, ny - q, ny)]
def test_worked_example() -> None:
beads, cost = align(X, Y)
assert beads == [(0, 1, 0, 1), (1, 3, 1, 2), (3, 4, 2, 3), (4, 5, 3, 4)]
assert math.isclose(cost, 3.4283, abs_tol=1e-4)
assert math.isclose(cost, alignment_cost(X, Y, beads), rel_tol=1e-12)
# the 2-1 bead joins 31 + 44 = 75 characters with 80
assert math.isclose(delta(75, 80), 5 / math.sqrt(6.8 * 77.5), rel_tol=1e-12)
def test_delete_or_merge() -> None:
# a short last sentence goes into a 2-1 bead, not into a 1-0 bead
beads, _ = align([40, 25, 30, 62, 12], [43, 58, 65])
assert beads == [(0, 1, 0, 1), (1, 3, 1, 2), (3, 5, 2, 3)]
def test_against_brute_force() -> None:
rng = random.Random(7)
for _ in range(150):
nx, ny = rng.randint(0, 5), rng.randint(0, 5)
x = [rng.randint(1, 120) for _ in range(nx)]
y = [rng.randint(1, 120) for _ in range(ny)]
beads, cost = align(x, y)
best = min(alignment_cost(x, y, b) for b in all_alignments(nx, ny))
assert math.isclose(cost, best, rel_tol=1e-9, abs_tol=1e-9)
assert math.isclose(alignment_cost(x, y, beads), cost, rel_tol=1e-9, abs_tol=1e-9)
# every sentence is in exactly one bead, in order
assert [b[0] for b in beads] + [nx] == [0] + [b[1] for b in beads]
assert [b[2] for b in beads] + [ny] == [0] + [b[3] for b in beads]
def test_count_of_alignments() -> None:
# the brute force really enumerates every path of the six steps
counts = {(0, 0): 1}
for i in range(4):
for j in range(4):
if (i, j) != (0, 0):
counts[(i, j)] = sum(counts.get((i - p, j - q), 0) for p, q in BEADS)
assert sum(1 for _ in all_alignments(3, 3)) == counts[(3, 3)]
def test_edges() -> None:
assert align([], []) == ([], 0.0)
beads, cost = align([30], [])
assert beads == [(0, 1, 0, 0)]
assert math.isclose(cost, bead_cost(30, 0, 1, 0))
beads, _ = align([], [10, 20])
assert beads == [(0, 0, 0, 1), (0, 0, 1, 2)]
# the program's delta is defined for 0-1 beads; the text form l1 = 0 is not
assert math.isclose(delta(0, 50), 50 / math.sqrt(6.8 * 25))
assert delta(0, 0) == 0.0
def test_priors() -> None:
assert math.isclose(sum(PRIORS.values()), 1.0988, rel_tol=1e-12)
assert math.isclose(bead_cost(50, 50, 1, 1), -math.log(0.89), rel_tol=1e-12)
def test_tail() -> None:
for x in (0.0, 0.5, 1.96, 5.0, 12.0, 29.0):
assert math.isclose(log_two_sided_tail(x), math.log(math.erfc(x / math.sqrt(2))), rel_tol=1e-12)
assert math.isclose(log_two_sided_tail(1.96), math.log(0.05), rel_tol=1e-3)
# the asymptotic branch joins the erfc branch at 30
below = math.log(math.erfc(29.999 / math.sqrt(2)))
assert math.isclose(log_two_sided_tail(30.0), below - (30.0**2 - 29.999**2) / 2, rel_tol=1e-6)
# far out the cost stays finite, where erfc itself is 0
assert math.erfc(60 / math.sqrt(2)) == 0.0
assert math.isfinite(log_two_sided_tail(60.0))
assert log_two_sided_tail(-3.0) == log_two_sided_tail(3.0)
History
William Gale and Kenneth Church presented the program at the ACL meeting of 1991, and the journal version with the C code appeared in Computational Linguistics in 1993. At the same meeting, Peter Brown, Jennifer Lai and Robert Mercer of IBM gave a length-based method that counted words, which they used on the Canadian Hansards. Gale and Church tested theirs on economic reports of the Union Bank of Switzerland in English, French and German. All but 4% of the sentences were aligned correctly, and they also aligned a sample of about 90 million words of the Hansards. The method became the standard first step to build sentence-aligned corpora for statistical machine translation.
References
- Gale and Church 1993, Section 4 (the distance measure and Table 5 of the match priors), Section 5 (the dynamic program), Section 6 (the evaluation), and the C program in the appendix
- Gale and Church 1991, the conference version
- Peter F. Brown, Jennifer C. Lai and Robert L. Mercer, Aligning sentences in parallel corpora, 29th Annual Meeting of the ACL, 1991, pages 169 to 176, the length-based alignment with lengths in words
- Philipp Koehn, Statistical Machine Translation, Cambridge University Press, 2010, Chapter 2 (Words, Sentences, Corpora)
About this page
The build computes these levels from the evidence in the repository. Each row says what the next level needs. Read what the levels mean.
| Ladder | Level | What the next level needs |
|---|---|---|
| Human proof | H1 sketch |
|
| Lean | L0 no Lean part |
|
| Code (python) | I0 not checked yet |
|
| Visual | V0 none |
|
| Writing | W2 basic |
|
Tag TXM3A8 Edit this page History Report an error Markdown