LTP
/

File size: 10,090 Bytes
6e79555
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
{
    "model": {
        "_ltp_target_": "ltp_core.models.ltp_model.LTPModule",
        "backbone": {
            "_ltp_target_": "ltp_core.models.utils.load_transformers",
            "config": {
                "return_dict": true,
                "output_hidden_states": false,
                "output_attentions": false,
                "torchscript": false,
                "use_bfloat16": false,
                "pruned_heads": {},
                "tie_word_embeddings": true,
                "is_encoder_decoder": false,
                "is_decoder": false,
                "add_cross_attention": false,
                "tie_encoder_decoder": false,
                "max_length": 20,
                "min_length": 0,
                "do_sample": false,
                "early_stopping": false,
                "num_beams": 1,
                "num_beam_groups": 1,
                "diversity_penalty": 0.0,
                "temperature": 1.0,
                "top_k": 50,
                "top_p": 1.0,
                "repetition_penalty": 1.0,
                "length_penalty": 1.0,
                "no_repeat_ngram_size": 0,
                "encoder_no_repeat_ngram_size": 0,
                "bad_words_ids": null,
                "num_return_sequences": 1,
                "chunk_size_feed_forward": 0,
                "output_scores": false,
                "return_dict_in_generate": false,
                "architectures": null,
                "finetuning_task": null,
                "id2label": {
                    "0": "LABEL_0",
                    "1": "LABEL_1"
                },
                "label2id": {
                    "LABEL_0": 0,
                    "LABEL_1": 1
                },
                "tokenizer_class": null,
                "prefix": null,
                "bos_token_id": null,
                "pad_token_id": 0,
                "eos_token_id": null,
                "sep_token_id": null,
                "decoder_start_token_id": null,
                "task_specific_params": null,
                "xla_device": null,
                "_name_or_path": "",
                "directionality": "bidi",
                "model_type": "electra",
                "vocab_size": 21128,
                "embedding_size": 768,
                "hidden_size": 768,
                "num_hidden_layers": 12,
                "num_attention_heads": 12,
                "intermediate_size": 3072,
                "hidden_act": "gelu",
                "hidden_dropout_prob": 0.1,
                "attention_probs_dropout_prob": 0.1,
                "max_position_embeddings": 512,
                "type_vocab_size": 2,
                "initializer_range": 0.02,
                "layer_norm_eps": 1e-12,
                "summary_type": "first",
                "summary_use_proj": true,
                "summary_activation": "gelu",
                "summary_last_dropout": 0.1,
                "position_embedding_type": "absolute",
                "transformers_version": "4.3.3"
            }
        },
        "processor": {
            "cws": {
                "_ltp_target_": "ltp_core.models.processor.TokenOnly"
            },
            "pos": {
                "_ltp_target_": "ltp_core.models.processor.WordsOnly"
            },
            "ner": {
                "_ltp_target_": "ltp_core.models.processor.WordsOnly"
            },
            "srl": {
                "_ltp_target_": "ltp_core.models.processor.WordsOnly"
            },
            "dep": {
                "_ltp_target_": "ltp_core.models.processor.WordsWithHead"
            },
            "sdp": {
                "_ltp_target_": "ltp_core.models.processor.WordsWithHead"
            }
        },
        "heads": {
            "cws": {
                "_ltp_target_": "ltp_core.models.components.token.MLPTokenClassifier",
                "input_size": 768,
                "num_labels": 2,
                "dropout": 0.1
            },
            "pos": {
                "_ltp_target_": "ltp_core.models.components.token.MLPTokenClassifier",
                "input_size": 768,
                "num_labels": 27,
                "dropout": 0.1
            },
            "ner": {
                "_ltp_target_": "ltp_core.models.components.token.RelTransformerTokenClassifier",
                "input_size": 768,
                "num_labels": 13,
                "dropout": 0.1,
                "num_heads": 4,
                "num_layers": 2
            },
            "srl": {
                "_ltp_target_": "ltp_core.models.components.token.BiaffineTokenClassifier",
                "input_size": 768,
                "hidden_size": 600,
                "num_labels": 97,
                "dropout": 0.1,
                "use_crf": true
            },
            "dep": {
                "_ltp_target_": "ltp_core.models.components.graph.BiaffineClassifier",
                "input_size": 768,
                "num_labels": 14,
                "dropout": 0.1,
                "arc_hidden_size": 500,
                "rel_hidden_size": 100
            },
            "sdp": {
                "_ltp_target_": "ltp_core.models.components.graph.BiaffineClassifier",
                "input_size": 768,
                "num_labels": 56,
                "arc_hidden_size": 600,
                "rel_hidden_size": 600
            }
        }
    },
    "nerual": true,
    "vocabs": {
        "cws": [
            "I-W",
            "B-W"
        ],
        "pos": [
            "a",
            "b",
            "c",
            "d",
            "e",
            "h",
            "i",
            "j",
            "k",
            "m",
            "n",
            "nd",
            "nh",
            "ni",
            "nl",
            "ns",
            "nt",
            "nz",
            "o",
            "p",
            "q",
            "r",
            "u",
            "v",
            "wp",
            "ws",
            "z"
        ],
        "ner": [
            "O",
            "B-Nh",
            "B-Ni",
            "B-Ns",
            "I-Nh",
            "I-Ni",
            "I-Ns",
            "E-Nh",
            "E-Ni",
            "E-Ns",
            "S-Nh",
            "S-Ni",
            "S-Ns"
        ],
        "srl": [
            "O",
            "B-A0",
            "B-A0-ADV",
            "B-A0-CND",
            "B-A0-CRD",
            "B-A0-MNR",
            "B-A0-PRD",
            "B-A0-PSE",
            "B-A0-PSR",
            "B-A0-QTY",
            "B-A1",
            "B-A1-CRD",
            "B-A1-DIS",
            "B-A1-FRQ",
            "B-A1-PRD",
            "B-A1-PSE",
            "B-A1-PSR",
            "B-A1-QTY",
            "B-A1-TPC",
            "B-A2",
            "B-A2-CRD",
            "B-A2-PRD",
            "B-A2-PSE",
            "B-A2-PSR",
            "B-A2-QTY",
            "B-A3",
            "B-A3-TMP",
            "B-A4",
            "B-ARGM-ADV",
            "B-ARGM-BNF",
            "B-ARGM-CND",
            "B-ARGM-CRD",
            "B-ARGM-DGR",
            "B-ARGM-DIR",
            "B-ARGM-DIS",
            "B-ARGM-EXT",
            "B-ARGM-FRQ",
            "B-ARGM-LOC",
            "B-ARGM-MNR",
            "B-ARGM-PRD",
            "B-ARGM-PRP",
            "B-ARGM-QTY",
            "B-ARGM-T",
            "B-ARGM-TMP",
            "B-ARGM-TPC",
            "B-rel-ADV",
            "B-rel-DIS",
            "B-rel-EXT",
            "B-rel-MNR",
            "I-A0",
            "I-A0-ADV",
            "I-A0-CND",
            "I-A0-CRD",
            "I-A0-MNR",
            "I-A0-PRD",
            "I-A0-PSE",
            "I-A0-PSR",
            "I-A0-QTY",
            "I-A1",
            "I-A1-CRD",
            "I-A1-DIS",
            "I-A1-FRQ",
            "I-A1-PRD",
            "I-A1-PSE",
            "I-A1-PSR",
            "I-A1-QTY",
            "I-A1-TPC",
            "I-A2",
            "I-A2-CRD",
            "I-A2-PRD",
            "I-A2-PSE",
            "I-A2-PSR",
            "I-A2-QTY",
            "I-A3",
            "I-A3-TMP",
            "I-A4",
            "I-ARGM-ADV",
            "I-ARGM-BNF",
            "I-ARGM-CND",
            "I-ARGM-CRD",
            "I-ARGM-DGR",
            "I-ARGM-DIR",
            "I-ARGM-DIS",
            "I-ARGM-EXT",
            "I-ARGM-FRQ",
            "I-ARGM-LOC",
            "I-ARGM-MNR",
            "I-ARGM-PRD",
            "I-ARGM-PRP",
            "I-ARGM-QTY",
            "I-ARGM-T",
            "I-ARGM-TMP",
            "I-ARGM-TPC",
            "I-rel-ADV",
            "I-rel-DIS",
            "I-rel-EXT",
            "I-rel-MNR"
        ],
        "dep": [
            "ADV",
            "ATT",
            "CMP",
            "COO",
            "DBL",
            "FOB",
            "HED",
            "IOB",
            "LAD",
            "POB",
            "RAD",
            "SBV",
            "VOB",
            "WP"
        ],
        "sdp": [
            "AGT",
            "CONT",
            "DATV",
            "EXP",
            "FEAT",
            "LINK",
            "LOC",
            "MANN",
            "MATL",
            "MEAS",
            "PAT",
            "REAS",
            "Root",
            "SCO",
            "STAT",
            "TIME",
            "TOOL",
            "dAGT",
            "dCONT",
            "dDATV",
            "dEXP",
            "dFEAT",
            "dLINK",
            "dLOC",
            "dMANN",
            "dMATL",
            "dMEAS",
            "dPAT",
            "dREAS",
            "dSCO",
            "dSTAT",
            "dTIME",
            "dTOOL",
            "eCOO",
            "ePREC",
            "eSUCC",
            "mDEPD",
            "mNEG",
            "mPUNC",
            "mRELA",
            "rAGT",
            "rCONT",
            "rDATV",
            "rEXP",
            "rFEAT",
            "rLINK",
            "rLOC",
            "rMANN",
            "rMATL",
            "rMEAS",
            "rPAT",
            "rREAS",
            "rSCO",
            "rSTAT",
            "rTIME",
            "rTOOL"
        ]
    }
}