<s>
Gestalt	B-Algorithm
pattern	I-Algorithm
matching	I-Algorithm
,	O
also	O
Ratcliff/Obershelp	B-Algorithm
pattern	I-Algorithm
recognition	I-Algorithm
,	O
is	O
a	O
string-matching	B-Algorithm
algorithm	I-Algorithm
for	O
determining	O
the	O
similarity	O
of	O
two	O
strings	O
.	O
</s>
<s>
The	O
matching	O
characters	O
are	O
defined	O
as	O
some	O
longest	B-Algorithm
common	I-Algorithm
substring	I-Algorithm
plus	O
recursively	O
the	O
number	O
of	O
matching	O
characters	O
in	O
the	O
non-matching	O
regions	O
on	O
both	O
sides	O
of	O
the	O
longest	B-Algorithm
common	I-Algorithm
substring	I-Algorithm
:	O
</s>
<s>
The	O
longest	B-Algorithm
common	I-Algorithm
substring	I-Algorithm
is	O
WIKIM	O
(	O
light	O
grey	O
)	O
with	O
5	O
characters	O
.	O
</s>
<s>
They	O
again	O
have	O
a	O
longest	B-Algorithm
common	I-Algorithm
substring	I-Algorithm
IA	O
(	O
dark	O
gray	O
)	O
with	O
length	O
2	O
.	O
</s>
<s>
The	O
Ratcliff/Obershelp	B-Algorithm
matching	O
characters	O
can	O
be	O
substantially	O
different	O
from	O
each	O
longest	O
common	O
subsequence	O
of	O
the	O
given	O
strings	O
.	O
</s>
<s>
For	O
example	O
and	O
have	O
as	O
their	O
only	O
longest	B-Algorithm
common	I-Algorithm
substring	I-Algorithm
,	O
and	O
no	O
common	O
characters	O
right	O
of	O
its	O
occurrence	O
,	O
and	O
likewise	O
left	O
,	O
leading	O
to	O
.	O
</s>
<s>
The	O
Python	B-Language
library	O
implementation	O
of	O
the	O
gestalt	B-Algorithm
pattern	I-Algorithm
matching	I-Algorithm
algorithm	O
is	O
not	O
commutative	O
:	O
</s>
<s>
The	O
Python	B-Language
difflib	O
library	O
,	O
which	O
was	O
introduced	O
in	O
version	O
2.1	O
,	O
implements	O
a	O
similar	O
algorithm	O
that	O
predates	O
the	O
Ratcliff-Obershelp	O
algorithm	O
.	O
</s>
