|
1
2
|
(*
* ENIAMlexSemantics is a library that assigns tokens with lexicosemantic information.
|
|
3
4
|
* Copyright (C) 2016-2017 Wojciech Jaworski <wjaworski atSPAMfree mimuw dot edu dot pl>
* Copyright (C) 2016-2017 Institute of Computer Science Polish Academy of Sciences
|
|
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
*
* This library is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*)
open ENIAMtokenizerTypes
open Xstd
|
|
23
24
25
26
27
28
29
|
type frame = {
selectors: (ENIAM_LCGlexiconTypes.selector * ENIAM_LCGlexiconTypes.selector_relation * string list) list;
meanings: ((*ENIAMwalTypes.meaning **) string * (string * int) list * float) list;
positions: ENIAMwalTypes.position list;
arole: string;
arole_attr: string;
arev: bool;
|
|
30
|
agf: string;
|
|
31
|
sem_args: string list;
|
|
32
|
rev_hipero: bool;
|
|
33
|
(* has_context: bool; *)
|
|
34
35
|
sopinion: ENIAMwalTypes.opinion;
fopinion: ENIAMwalTypes.opinion;
|
|
36
37
|
}
|
|
38
|
let empty_frame = {selectors=[]; meanings=[]; positions=[]; arole=""; arole_attr=""; arev=false; agf=""; sem_args=[]; rev_hipero=false; (*has_context=false;*)
|
|
39
|
sopinion=ENIAMwalTypes.Nieokreslony; fopinion=ENIAMwalTypes.Nieokreslony}
|
|
40
|
|
|
41
|
type lex_sem = {
|
|
42
|
schemata: ((ENIAM_LCGlexiconTypes.selector * ENIAM_LCGlexiconTypes.selector_relation * string list) list *
|
|
43
|
(string * string list) list * (* sensy *)
|
|
44
45
|
(ENIAM_LCGtypes.direction * ENIAM_LCGtypes.grammar_symbol) list) list;
lex_entries: ((ENIAM_LCGlexiconTypes.selector * ENIAM_LCGlexiconTypes.selector_relation * string list) list *
|
|
46
|
ENIAM_LCGtypes.grammar_symbol) list;
|
|
47
|
frames: frame list;
|
|
48
|
(* cats: (string * string list) list; *)
|
|
49
50
51
|
}
let empty_lex_sem = {
|
|
52
|
schemata=[]; lex_entries=[]; frames=[]; (*cats=["X",["X"]]*)}
|
|
53
|
|
|
54
55
|
let hipero_threshold = 3
let unknown_meaning_weight = -1.
|
|
56
57
58
59
|
let lu_filename = resource_path ^ "/plWordnet/lu.tab"
let ex_hipo_filename = resource_path ^ "/plWordnet/ex_hipo.tab"
let syn_filename = resource_path ^ "/plWordnet/syn.tab"
|
|
60
61
62
|
let predef_filename = resource_path ^ "/lexSemantics/predef_prefs.tab"
let proper_classes_filename = resource_path ^ "/lexSemantics/proper_classes.tab"
|
|
63
64
|
let proj_filename = ENIAMwalTypes.data_path ^ "/projections.tab"
|