A coupled parallelsentence contains two sources, two respective
translations and their corresponding attributes
|
__init__(self,
ps1,
ps2=None,
**kwargs)
Constructor @type source SimpleSentence @param source The source text
of the parallel sentence @type translations list ( SimpleSentence )
@param translations A list of given translations @type reference
SimpleSentence @param reference The desired translation provided by
the system @type attributes dict { String name , String value }
@param the attributes that describe the parallel sentence |
source code
|
|
|
|
|
_generate_rank(self)
Generates rank attribute after comparing the scores of the two
sentences |
source code
|
|
{str, str}
|
|
|
|
({str: str}, {str: str})
|
|
|
_collapse_simplesentence_attributes(self,
ps1,
ps2)
Creates a flat dictionary of attributes for the doubled parallel
sentence, containing attributes from its ingredients |
source code
|
|
|
|
Inherited from parallelsentence.ParallelSentence :
__eq__ ,
__gt__ ,
__lt__ ,
__str__ ,
add_attributes ,
add_judgment_id ,
get_attribute ,
get_attribute_names ,
get_attributes ,
get_compact_id ,
get_compact_judgment_id ,
get_filtered_target_attribute_values ,
get_judgment_id ,
get_nested_attribute_names ,
get_pairwise_parallelsentences ,
get_rank ,
get_ranking ,
get_reference ,
get_source ,
get_target_attribute_values ,
get_translations ,
get_tuple_id ,
has_judgment_id ,
import_indexed_parallelsentence ,
import_missing_parallelsentence ,
merge_parallelsentence ,
recover_attributes ,
remove_ties ,
serialize ,
set_id ,
set_langsrc ,
set_langtgt ,
set_reference ,
set_source ,
set_translations
Inherited from object :
__delattr__ ,
__format__ ,
__getattribute__ ,
__hash__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__setattr__ ,
__sizeof__ ,
__subclasshook__
|