wordmap
Version:
Multi-Lingual Word Alignment Prediction
26 lines (25 loc) • 837 B
TypeScript
import Alignment from "../structures/Alignment";
import FrequencyIndex from "./FrequencyIndex";
/**
* An index of alignment frequencies
*/
export default class AlignmentIndex extends FrequencyIndex {
/**
* Reads a value from the index
* @param alignment - the alignment index to read. This may be a specific key, or the alignment object to read the default key.
*/
read(alignment: Alignment | string): number;
/**
* Writes a value to the index
* @deprecated - use {@link increment} instead
* @param {Alignment} alignment
* @param {number} value
*/
write(alignment: Alignment, value: number): void;
/**
* Increments a value in the index
* @param {Alignment} alignment
* @param {number} value
*/
increment(alignment: Alignment, value?: number): void;
}