@keymanapp/kmc-model 18.0.53-alpha → 18.0.55-alpha
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/src/build-trie.d.ts +39 -39
- package/build/src/build-trie.js +374 -374
- package/build/src/build-trie.js.map +1 -1
- package/build/src/compiler-callbacks.d.ts +3 -3
- package/build/src/compiler-callbacks.js +4 -4
- package/build/src/join-word-breaker-decorator.d.ts +9 -9
- package/build/src/join-word-breaker-decorator.js +120 -120
- package/build/src/join-word-breaker-decorator.js.map +1 -1
- package/build/src/lexical-model-compiler.d.ts +87 -87
- package/build/src/lexical-model-compiler.js +260 -260
- package/build/src/lexical-model-compiler.js.map +1 -1
- package/build/src/lexical-model.d.ts +143 -143
- package/build/src/lexical-model.js +5 -5
- package/build/src/main.d.ts +3 -3
- package/build/src/main.js +2 -2
- package/build/src/model-compiler-messages.d.ts +56 -56
- package/build/src/model-compiler-messages.js +63 -63
- package/build/src/model-defaults.d.ts +55 -55
- package/build/src/model-defaults.js +101 -101
- package/build/src/model-defaults.js.map +1 -1
- package/build/src/model-definitions.d.ts +70 -70
- package/build/src/model-definitions.js +182 -182
- package/build/src/model-definitions.js.map +1 -1
- package/build/src/script-overrides-decorator.d.ts +3 -3
- package/build/src/script-overrides-decorator.js +63 -63
- package/build/src/script-overrides-decorator.js.map +1 -1
- package/package.json +8 -9
|
@@ -1,40 +1,40 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* A word list is (conceptually) an array of pairs: the concrete word form itself + a
|
|
3
|
-
* non-negative count.
|
|
4
|
-
*
|
|
5
|
-
* Since each word should only appear once within the list, we represent it with
|
|
6
|
-
* an associative array pattern keyed by the wordform.
|
|
7
|
-
*/
|
|
8
|
-
export type WordList = {
|
|
9
|
-
[wordform: string]: number;
|
|
10
|
-
};
|
|
11
|
-
/**
|
|
12
|
-
* Returns a data structure that can be loaded by the TrieModel.
|
|
13
|
-
*
|
|
14
|
-
* It implements a **weighted** trie, whose indices (paths down the trie) are
|
|
15
|
-
* generated by a search key, and not concrete wordforms themselves.
|
|
16
|
-
*
|
|
17
|
-
* @param sourceFiles an array of source files that will be read to generate the trie.
|
|
18
|
-
*/
|
|
19
|
-
export declare function createTrieDataStructure(filenames: string[], searchTermToKey?: (wf: string) => string): string;
|
|
20
|
-
/**
|
|
21
|
-
* Parses a word list from a file, merging duplicate entries.
|
|
22
|
-
*
|
|
23
|
-
* The word list may be encoded in:
|
|
24
|
-
*
|
|
25
|
-
* - UTF-8, with or without BOM [exported by most software]
|
|
26
|
-
* - UTF-16, little endian, with BOM [exported by Microsoft Excel]
|
|
27
|
-
*
|
|
28
|
-
* @param wordlist word list to merge entries into (may have existing entries)
|
|
29
|
-
* @param filename filename of the word list
|
|
30
|
-
*/
|
|
31
|
-
export declare function parseWordListFromFilename(wordlist: WordList, filename: string): void;
|
|
32
|
-
/**
|
|
33
|
-
* Parses a word list from a string. The string should have multiple lines
|
|
34
|
-
* with LF or CRLF line terminators.
|
|
35
|
-
*
|
|
36
|
-
* @param wordlist word list to merge entries into (may have existing entries)
|
|
37
|
-
* @param filename filename of the word list
|
|
38
|
-
*/
|
|
39
|
-
export declare function parseWordListFromContents(wordlist: WordList, contents: string): void;
|
|
1
|
+
/**
|
|
2
|
+
* A word list is (conceptually) an array of pairs: the concrete word form itself + a
|
|
3
|
+
* non-negative count.
|
|
4
|
+
*
|
|
5
|
+
* Since each word should only appear once within the list, we represent it with
|
|
6
|
+
* an associative array pattern keyed by the wordform.
|
|
7
|
+
*/
|
|
8
|
+
export type WordList = {
|
|
9
|
+
[wordform: string]: number;
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* Returns a data structure that can be loaded by the TrieModel.
|
|
13
|
+
*
|
|
14
|
+
* It implements a **weighted** trie, whose indices (paths down the trie) are
|
|
15
|
+
* generated by a search key, and not concrete wordforms themselves.
|
|
16
|
+
*
|
|
17
|
+
* @param sourceFiles an array of source files that will be read to generate the trie.
|
|
18
|
+
*/
|
|
19
|
+
export declare function createTrieDataStructure(filenames: string[], searchTermToKey?: (wf: string) => string): string;
|
|
20
|
+
/**
|
|
21
|
+
* Parses a word list from a file, merging duplicate entries.
|
|
22
|
+
*
|
|
23
|
+
* The word list may be encoded in:
|
|
24
|
+
*
|
|
25
|
+
* - UTF-8, with or without BOM [exported by most software]
|
|
26
|
+
* - UTF-16, little endian, with BOM [exported by Microsoft Excel]
|
|
27
|
+
*
|
|
28
|
+
* @param wordlist word list to merge entries into (may have existing entries)
|
|
29
|
+
* @param filename filename of the word list
|
|
30
|
+
*/
|
|
31
|
+
export declare function parseWordListFromFilename(wordlist: WordList, filename: string): void;
|
|
32
|
+
/**
|
|
33
|
+
* Parses a word list from a string. The string should have multiple lines
|
|
34
|
+
* with LF or CRLF line terminators.
|
|
35
|
+
*
|
|
36
|
+
* @param wordlist word list to merge entries into (may have existing entries)
|
|
37
|
+
* @param filename filename of the word list
|
|
38
|
+
*/
|
|
39
|
+
export declare function parseWordListFromContents(wordlist: WordList, contents: string): void;
|
|
40
40
|
//# sourceMappingURL=build-trie.d.ts.map
|