blob: 1dbf83bf2690f8e53e98ccbfc18f89704cbddb0f [file] [log] [blame]
Nils Diewald0e6992a2015-04-14 20:13:52 +00001requirejs.config({
2 baseUrl: '../js/src',
3 paths : {
4 'lib': '../lib'
5 }
6});
7
8// Parse and show the table
9// Override getMatchInfo API call
10require(['init'], function () {
11
Nils Diewald4347ee92015-05-04 20:32:48 +000012 var snippet = "<span title=\"cnx/l:meist\">" +
Nils Diewald0e6992a2015-04-14 20:13:52 +000013 " <span title=\"cnx/p:ADV\">" +
14 " <span title=\"cnx/syn:@PREMOD\">" +
15 " <span title=\"mate/l:meist\">" +
16 " <span title=\"mate/p:ADV\">" +
17 " <span title=\"opennlp/p:ADV\">meist</span>" +
18 " </span>" +
19 " </span>" +
20 " </span>" +
21 " </span>" +
22 "</span>" +
23 "<span title=\"cnx/l:deutlich\">" +
24 " <span title=\"cnx/p:A\">" +
25 " <span title=\"cnx/syn:@PREMOD\">" +
26 " <span title=\"mate/l:deutlich\">" +
27 " <span title=\"mate/m:degree:pos\">" +
28 " <span title=\"mate/p:ADJD\">" +
29 " <span title=\"opennlp/p:ADJD\">deutlich</span>" +
30 " </span>" +
31 " </span>" +
32 " </span>" +
33 " </span>" +
34 " </span>" +
35 "</span>" +
36 "<span title=\"cnx/l:fähig\">" +
37 " <span title=\"cnx/l:leistung\">" +
38 " <span title=\"cnx/p:A\">" +
39 " <span title=\"cnx/syn:@NH\">" +
40 " <span title=\"mate/l:leistungsfähig\">" +
41 " <span title=\"mate/m:degree:comp\">" +
42 " <span title=\"mate/p:ADJD\">" +
43 " <span title=\"opennlp/p:ADJD\">leistungsfähiger</span>" +
44 " </span>" +
45 " </span>" +
46 " </span>" +
47 " </span>" +
48 " </span>" +
49 " </span>" +
50 "</span>";
51
Akronad1e46a2018-09-19 15:55:40 +020052 snippet = "<span class=\"context-left\"></span>" +
53 "<span class=\"match\">"+
54 " <span title=\"corenlp\/p:KOUI\">"+
55 " <span title=\"marmot\/p:KOUI\">"+
56 " <span title=\"opennlp\/p:KOUI\">"+
57 " <span title=\"tt\/l:um\">"+
58 " <span title=\"tt\/l:um\">"+
59 " <span title=\"tt\/p:APPR\">"+
60 " <span title=\"tt\/p:KOUI\">Um</span>" +
61 " </span>" +
62 " </span>" +
63 " </span>" +
64 " </span>" +
65 " </span>" +
66 " </span>"+
67 " " +
68 " <span title=\"corenlp\/p:ART\">"+
69 " <span title=\"marmot\/m:case:acc\">"+
70 " <span title=\"marmot\/m:gender:masc\">"+
71 " <span title=\"marmot\/m:number:pl\">"+
72 " <span title=\"marmot\/p:ART\">"+
73 " <span title=\"opennlp\/p:ART\">"+
74 " <span title=\"tt\/l:die\">" +
75 " <span title=\"tt\/p:ART\">die</span>" +
76 " </span>" +
77 " </span>" +
78 " </span>" +
79 " </span>" +
80 " </span>" +
81 " </span>" +
82 " </span>" +
83 " " +
84 " <span title=\"corenlp\/p:APPR\">"+
85 " <span title=\"marmot\/p:APPR\">"+
86 " <span title=\"opennlp\/p:APPR\">"+
87 " <span title=\"tt\/l:von\">"+
88 " <span title=\"tt\/p:APPR\">von</span>" +
89 " </span>" +
90 " </span>" +
91 " </span>" +
92 " </span>" +
93 " " +
94 " <span title=\"corenlp\/p:PPOSAT\">"+
95 " <span title=\"marmot\/m:case:dat\">"+
96 " <span title=\"marmot\/m:gender:masc\">"+
97 " <span title=\"marmot\/m:number:sg\">"+
98 " <span title=\"marmot\/p:PPOSAT\">"+
99 " <span title=\"opennlp\/p:PPOSAT\">"+
100 " <span title=\"tt\/l:sein\">"+
101 " <span title=\"tt\/p:PPOSAT\">seinem</span>" +
102 " </span>" +
103 " </span>" +
104 " </span>" +
105 " </span>" +
106 " </span>" +
107 " </span>" +
108 " </span>" +
109 " " +
110 " <span title=\"corenlp\/p:NN\">"+
111 " <span title=\"marmot\/m:case:dat\">"+
112 " <span title=\"marmot\/m:gender:masc\">"+
113 " <span title=\"marmot\/m:number:sg\">"+
114 " <span title=\"marmot\/p:NN\">"+
115 " <span title=\"opennlp\/p:NN\">"+
116 " <span title=\"tt\/l:Großvater\">"+
117 " <span title=\"tt\/p:NN\">Großvater</span>" +
118 " </span>" +
119 " </span>" +
120 " </span>" +
121 " </span>" +
122 " </span>" +
123 " </span>" +
124 " </span>" +
125 " " +
126 " <span title=\"corenlp\/p:ADJA\">" +
127 " <span title=\"marmot\/m:case:acc\">" +
128 " <span title=\"marmot\/m:degree:pos\">" +
129 " <span title=\"marmot\/m:gender:fem\">" +
130 " <span title=\"marmot\/m:number:sg\">" +
131 " <span title=\"marmot\/p:ADJA\">" +
132 " <span title=\"opennlp\/p:ADJA\">" +
133 " <span title=\"tt\/l:gepflanzt\">" +
134 " <span title=\"tt\/p:ADJA\">gepflanzte</span>" +
135 " </span>" +
136 " </span>" +
137 " </span>" +
138 " </span>" +
139 " </span>" +
140 " </span>" +
141 " </span>" +
142 " </span>" +
143 " " +
144 " <span title=\"corenlp\/p:NN\">" +
145 " <span title=\"marmot\/m:case:acc\">" +
146 " <span title=\"marmot\/m:gender:fem\">" +
147 " <span title=\"marmot\/m:number:sg\">" +
148 " <span title=\"marmot\/p:NN\">" +
149 " <span title=\"opennlp\/p:NN\">" +
150 " <span title=\"tt\/l:Esche\">" +
151 " <span title=\"tt\/p:NN\">Esche</span>" +
152 " </span>" +
153 " </span>" +
154 " </span>" +
155 " </span>" +
156 " </span>" +
157 " </span>" +
158 " </span>" +
159 " " +
160 " <span title=\"corenlp\/p:VAFIN\">" +
161 " <span title=\"marmot\/m:mood:ind\">" +
162 " <span title=\"marmot\/m:number:sg\">" +
163 " <span title=\"marmot\/m:person:3\">" +
164 " <span title=\"marmot\/m:tense:pres\">" +
165 " <span title=\"marmot\/p:VAFIN\">" +
166 " <span title=\"opennlp\/p:VAFIN\">" +
167 " <span title=\"tt\/l:haben\">" +
168 " <span title=\"tt\/p:VAFIN\">hat</span>" +
169 " </span>" +
170 " </span>" +
171 " </span>" +
172 " </span>" +
173 " </span>" +
174 " </span>" +
175 " </span>" +
176 " </span>" +
177 " " +
178 " <span title=\"corenlp\/p:NE\">" +
179 " <span title=\"marmot\/m:case:nom\">" +
180 " <span title=\"marmot\/m:gender:*\">" +
181 " <span title=\"marmot\/m:number:sg\">" +
182 " <span title=\"marmot\/p:NE\">" +
183 " <span title=\"opennlp\/p:NE\">" +
184 " <span title=\"tt\/l:Behrens\">" +
185 " <span title=\"tt\/p:NE\">Behrens</span>" +
186 " </span>" +
187 " </span>" +
188 " </span>" +
189 " </span>" +
190 " </span>" +
191 " </span>" +
192 " </span>" +
193 " " +
194 " <span title=\"corenlp\/p:APPR\">" +
195 " <span title=\"marmot\/p:APPR\">" +
196 " <span title=\"opennlp\/p:APPR\">" +
197 " <span title=\"tt\/l:bei\">" +
198 " <span title=\"tt\/p:APPR\">bei</span>" +
199 " </span>" +
200 " </span>" +
201 " </span>" +
202 " </span>" +
203 " " +
204 " <span title=\"corenlp\/p:ART\">" +
205 " <span title=\"marmot\/m:case:dat\">" +
206 " <span title=\"marmot\/m:gender:fem\">" +
207 " <span title=\"marmot\/m:number:sg\">" +
208 " <span title=\"marmot\/p:ART\">" +
209 " <span title=\"opennlp\/p:ART\">" +
210 " <span title=\"tt\/l:die\">" +
211 " <span title=\"tt\/p:ART\">der</span>" +
212 " </span>" +
213 " </span>" +
214 " </span>" +
215 " </span>" +
216 " </span>" +
217 " </span>" +
218 " </span>" +
219 " " +
220 " <span title=\"corenlp\/p:NN\">" +
221 " <span title=\"marmot\/m:case:dat\">" +
222 " <span title=\"marmot\/m:gender:fem\">" +
223 " <span title=\"marmot\/m:number:sg\">" +
224 " <span title=\"marmot\/p:NN\">" +
225 " <span title=\"opennlp\/p:NN\">" +
226 " <span title=\"tt\/l:Vergrößerung\">" +
227 " <span title=\"tt\/p:NN\">Vergrößerung</span>" +
228 " </span>" +
229 " </span>" +
230 " </span>" +
231 " </span>" +
232 " </span>" +
233 " </span>" +
234 " </span>" +
235 " " +
236 " <span title=\"corenlp\/p:ART\">" +
237 " <span title=\"marmot\/m:case:gen\">" +
238 " <span title=\"marmot\/m:gender:neut\">" +
239 " <span title=\"marmot\/m:number:sg\">" +
240 " <span title=\"marmot\/p:ART\">" +
241 " <span title=\"opennlp\/p:ART\">" +
242 " <span title=\"tt\/l:die\">" +
243 " <span title=\"tt\/p:ART\">des</span>" +
244 " </span>" +
245 " </span>" +
246 " </span>" +
247 " </span>" +
248 " </span>" +
249 " </span>" +
250 " </span>" +
251 " " +
252 " <span title=\"corenlp\/p:NN\">" +
253 " <span title=\"marmot\/m:case:gen\">" +
254 " <span title=\"marmot\/m:gender:neut\">" +
255 " <span title=\"marmot\/m:number:sg\">" +
256 " <span title=\"marmot\/p:NN\">" +
257 " <span title=\"opennlp\/p:NN\">" +
258 " <span title=\"tt\/l:Laden\">" +
259 " <span title=\"tt\/p:NN\">Ladens</span>" +
260 " </span>" +
261 " </span>" +
262 " </span>" +
263 " </span>" +
264 " </span>" +
265 " </span>" +
266 " </span>" +
267 " " +
268 " <span title=\"corenlp\/p:ADV\">" +
269 " <span title=\"marmot\/p:ADV\">" +
270 " <span title=\"opennlp\/p:ADV\">" +
271 " <span title=\"tt\/l:einfach\">" +
272 " <span title=\"tt\/p:ADJD\">einfach</span>" +
273 " </span>" +
274 " </span>" +
275 " </span>" +
276 " </span>" +
277 " " +
278 " <span title=\"corenlp\/p:VVPP\">" +
279 " <span title=\"marmot\/p:VVPP\">" +
280 " <span title=\"opennlp\/p:VVPP\">" +
281 " <span title=\"tt\/l:herumbauen\">" +
282 " <span title=\"tt\/p:VVPP\">herumgebaut</span>" +
283 " </span>" +
284 " </span>" +
285 " </span>" +
286 " </span>" +
287 " : " +
288 " <span title=\"corenlp\/p:ADV\">" +
289 " <span title=\"marmot\/p:ADV\">" +
290 " <span title=\"opennlp\/p:ADV\">" +
291 " <span title=\"tt\/l:nun\">" +
292 " <span title=\"tt\/p:ADV\">Nun</span>" +
293 " </span>" +
294 " </span>" +
295 " </span>" +
296 " </span>" +
297 " " +
298 " <span title=\"corenlp\/p:VVFIN\">" +
299 " <span title=\"marmot\/m:mood:ind\">" +
300 " <span title=\"marmot\/m:number:sg\">" +
301 " <span title=\"marmot\/m:person:3\">" +
302 " <span title=\"marmot\/m:tense:pres\">" +
303 " <span title=\"marmot\/p:VVFIN\">" +
304 " <span title=\"opennlp\/p:VVFIN\">" +
305 " <span title=\"tt\/l:stehen\">" +
306 " <span title=\"tt\/p:VVFIN\">steht</span>" +
307 " </span>" +
308 " </span>" +
309 " </span>" +
310 " </span>" +
311 " </span>" +
312 " </span>" +
313 " </span>" +
314 " </span>" +
315 " " +
316 " <mark>" +
317 " <span title=\"corenlp\/p:ART\">" +
318 " <span title=\"marmot\/m:case:nom\">" +
319 " <span title=\"marmot\/m:gender:masc\">" +
320 " <span title=\"marmot\/m:number:sg\">" +
321 " <span title=\"marmot\/p:ART\">" +
322 " <span title=\"opennlp\/p:ART\">" +
323 " <span title=\"tt\/l:die\">" +
324 " <span title=\"tt\/p:ART\">der</span>" +
325 " </span>" +
326 " </span>" +
327 " </span>" +
328 " </span>" +
329 " </span>" +
330 " </span>" +
331 " </span>" +
332 " " +
333 " <span title=\"corenlp\/p:ADJA\">" +
334 " <span title=\"marmot\/m:case:nom\">" +
335 " <span title=\"marmot\/m:degree:pos\">" +
336 " <span title=\"marmot\/m:gender:masc\">" +
337 " <span title=\"marmot\/m:number:sg\">" +
338 " <span title=\"marmot\/p:ADJA\">" +
339 " <span title=\"opennlp\/p:ADJA\">" +
340 " <span title=\"tt\/l:alt\">" +
341 " <span title=\"tt\/p:ADJA\">alte</span>" +
342 " </span>" +
343 " </span>" +
344 " </span>" +
345 " </span>" +
346 " </span>" +
347 " </span>" +
348 " </span>" +
349 " </span>" +
350 " " +
351 " <span title=\"corenlp\/p:NN\">" +
352 " <span title=\"marmot\/m:case:nom\">" +
353 " <span title=\"marmot\/m:gender:masc\">" +
354 " <span title=\"marmot\/m:number:sg\">" +
355 " <span title=\"marmot\/p:NN\">" +
356 " <span title=\"opennlp\/p:NN\">" +
357 " <span title=\"tt\/l:Baum\">" +
358 " <span title=\"tt\/p:NN\">Baum</span>" +
359 " </span>" +
360 " </span>" +
361 " </span>" +
362 " </span>" +
363 " </span>" +
364 " </span>" +
365 " </span>" +
366 " " +
367 " </mark> <span title=\"corenlp\/p:ADV\">" +
368 " <span title=\"marmot\/p:ADV\">" +
369 " <span title=\"opennlp\/p:ADV\">" +
370 " <span title=\"tt\/l:mitten\">" +
371 " <span title=\"tt\/p:ADV\">mitten</span>" +
372 " </span>" +
373 " </span>" +
374 " </span>" +
375 " </span>" +
376 " " +
377 " <span title=\"corenlp\/p:APPR\">" +
378 " <span title=\"marmot\/p:APPR\">" +
379 " <span title=\"opennlp\/p:APPR\">" +
380 " <span title=\"tt\/l:in\">" +
381 " <span title=\"tt\/p:APPR\">in</span>" +
382 " </span>" +
383 " </span>" +
384 " </span>" +
385 " </span>" +
386 " " +
387 " <span title=\"corenlp\/p:ART\">" +
388 " <span title=\"marmot\/m:case:dat\">" +
389 " <span title=\"marmot\/m:gender:fem\">" +
390 " <span title=\"marmot\/m:number:sg\">" +
391 " <span title=\"marmot\/p:ART\">" +
392 " <span title=\"opennlp\/p:ART\">" +
393 " <span title=\"tt\/l:die\">" +
394 " <span title=\"tt\/p:ART\">der</span>" +
395 " </span>" +
396 " </span>" +
397 " </span>" +
398 " </span>" +
399 " </span>" +
400 " </span>" +
401 " </span>" +
402 " " +
403 " <span title=\"marmot\/p:TRUNC\">" +
404 " <span title=\"opennlp\/p:TRUNC\">" +
405 " <span title=\"tt\/l:Obst-\">" +
406 " <span title=\"tt\/p:TRUNC\">Obst-</span>" +
407 " </span>" +
408 " </span>" +
409 " </span>" +
410 " " +
411 " <span title=\"corenlp\/p:KON\">" +
412 " <span title=\"marmot\/p:KON\">" +
413 " <span title=\"opennlp\/p:KON\">" +
414 " <span title=\"tt\/l:und\">" +
415 " <span title=\"tt\/p:KON\">und</span>" +
416 " </span>" +
417 " </span>" +
418 " </span>" +
419 " </span>" +
420 " " +
421 " <span title=\"corenlp\/p:NN\">" +
422 " <span title=\"marmot\/m:case:gen\">" +
423 " <span title=\"marmot\/m:gender:fem\">" +
424 " <span title=\"marmot\/m:number:sg\">" +
425 " <span title=\"marmot\/p:NN\">" +
426 " <span title=\"opennlp\/p:NN\">" +
427 " <span title=\"tt\/l:Gemüseabteilung\">" +
428 " <span title=\"tt\/p:NN\">Gemüseabteilung</span>" +
429 " </span>" +
430 " </span>" +
431 " </span>" +
432 " </span>" +
433 " </span>" +
434 " </span>" +
435 " </span>" +
436 " ." +
437 "</span>" +
438 "<span class=\"context-right\">" +
439 "</span>";
440
Akron5dc31172019-05-15 18:43:48 +0200441 // with cut
Akron083ec572019-05-16 18:30:40 +0200442 snippet = "<span class=\"context-left\"><\/span>"+
443 "<span class=\"match\">" +
Akron1a780fe2019-05-21 15:59:00 +0200444 "<span class=\"cutted\"><\/span>" +
445 "Außerdem " +
Akron083ec572019-05-16 18:30:40 +0200446 "<span title=\"cnx/l:meist\">" +
Akron5dc31172019-05-15 18:43:48 +0200447 " <span title=\"cnx/p:ADV\">" +
448 " <span title=\"cnx/syn:@PREMOD\">" +
449 " <span title=\"mate/l:meist\">" +
450 " <span title=\"mate/p:ADV\">" +
451 " <span title=\"opennlp/p:ADV\">meist</span>" +
452 " </span>" +
453 " </span>" +
454 " </span>" +
455 " </span>" +
456 "</span>" +
457 "<span title=\"cnx/l:deutlich\">" +
458 " <span title=\"cnx/p:A\">" +
459 " <span title=\"cnx/syn:@PREMOD\">" +
460 " <span title=\"mate/l:deutlich\">" +
461 " <span title=\"mate/m:degree:pos\">" +
462 " <span title=\"mate/p:ADJD\">" +
463 " <span title=\"opennlp/p:ADJD\">deutlich</span>" +
464 " </span>" +
465 " </span>" +
466 " </span>" +
467 " </span>" +
468 " </span>" +
469 "</span>" +
470 "<span title=\"cnx/l:fähig\">" +
471 " <span title=\"cnx/l:leistung\">" +
472 " <span title=\"cnx/p:A\">" +
473 " <span title=\"cnx/syn:@NH\">" +
474 " <span title=\"mate/l:leistungsfähig\">" +
475 " <span title=\"mate/m:degree:comp\">" +
476 " <span title=\"mate/p:ADJD\">" +
477 " <span title=\"opennlp/p:ADJD\">leistungsfähiger</span>" +
478 " </span>" +
479 " </span>" +
480 " </span>" +
481 " </span>" +
482 " </span>" +
483 " </span>" +
Akron083ec572019-05-16 18:30:40 +0200484 " und robust sind auch die anderen Traktoren, die hier der Übersicht wegen keine Erwähnung finden können." +
485 "<span class=\"cutted\"><\/span>" +
486 "</span>"+
Akron5dc31172019-05-15 18:43:48 +0200487 "</span>";
488
Akron98a933f2016-08-11 00:19:17 +0200489 var treeSnippet =
Nils Diewald0e6992a2015-04-14 20:13:52 +0000490 "<span class=\"context-left\"></span>" +
491 "<span class=\"match\">" +
492 " <span title=\"xip/c:MC\">" +
493 " <span title=\"xip/c:TOP\">" +
494 " <span title=\"xip/c:PP\">" +
495 " <span title=\"xip/c:PREP\">Mit</span>" +
496 " <span title=\"xip/c:NP\">" +
497 " <span title=\"xip/c:DET\">dieser</span>" +
498 " <span title=\"xip/c:NPA\">" +
499 " <span title=\"xip/c:NOUN\">Methode</span>" +
500 " </span>" +
501 " </span>" +
502 " </span>" +
503 " <span title=\"xip/c:VERB\">ist</span>" +
Akron98a933f2016-08-11 00:19:17 +0200504 " <mark>" +
505 " <span title=\"xip/c:NP\">" +
506 " <span title=\"xip/c:PRON\">es</span>" +
507 " </span>" +
508 " <span title=\"xip/c:AP\">" +
509 " <span title=\"xip/c:ADV\">nun</span>" +
510 " <span title=\"xip/c:ADJ\">möglich</span>" +
511 " </span>" +
512 " </mark>" +
Nils Diewald0e6992a2015-04-14 20:13:52 +0000513 " <span title=\"xip/c:ADV\">z. B.</span>" +
514 " <span title=\"xip/c:NPA\">" +
515 " <span title=\"xip/c:NP\">" +
516 " <span title=\"xip/c:NOUN\">Voice</span>" +
517 " </span>" +
518 " </span>" + "(" +
519 " <span title=\"xip/c:INS\">" +
520 " <span title=\"xip/c:NPA\">" +
521 " <span title=\"xip/c:NP\">" +
522 " <span title=\"xip/c:NOUN\">Sprache</span>" +
523 " </span>" +
524 " </span>" +
525 " </span>" + ")" +
526 " <span title=\"xip/c:VERB\">bevorzugt</span>" +
527 " <span title=\"xip/c:PP\">" +
528 " <span title=\"xip/c:PREP\">in</span>" +
529 " <span title=\"xip/c:NP\">" +
530 " <span title=\"xip/c:PRON\">der</span>" +
531 " </span>" +
532 " <span title=\"xip/c:NPA\">" +
533 " <span title=\"xip/c:NP\">" +
534 " <span title=\"xip/c:NOUN\">Bridge</span>" +
535 " </span>" +
536 " </span>" +
537 " </span>" +
538 " <span title=\"xip/c:INFC\">" +
539 " <span title=\"xip/c:INS\">" +
540 " <span title=\"xip/c:VERB\">weiterzugeben</span>" +
541 " </span>" +
542 " </span>" +
543 " </span>" +
544 " </span>" +
545 "</span>" +
546 "<span class=\"context-right\"></span>";
547
Akronaa01dca2018-02-05 19:51:28 +0100548
549 var relSnippet =
550 "<span class=\"context-left\"></span>"+
551 "<span class=\"match\">"+
552 " <span xml:id=\"token-WDD17/982/72848-p15836-15839\">"+
553 " <span xlink:title=\"lwc/d:NK\" xlink:show=\"none\" xlink:href=\"#token-WDD17/982/72848-p15838\">Ein</span>"+
554 " "+
555 " <span xlink:title=\"lwc/d:NK\" xlink:show=\"none\" xlink:href=\"#token-WDD17/982/72848-p15838\">letztes</span>"+
556 " "+
557 " <span xml:id=\"token-WDD17/982/72848-p15838\">"+
558 // s1464_n2 "ein" -> ":"
559 " <span xlink:title=\"lwc/d:--\" xlink:show=\"none\" xlink:href=\"#token-WDD17/982/72848-p15836-15839\">mal</span>"+
560 " </span>"+
561 ": "+
562 " <span xml:id=\"token-WDD17/982/72848-p15839-15840\">"+
563 " <span xlink:title=\"lwc/d:--\" xlink:show=\"none\" xlink:href=\"#token-WDD17/982/72848-p15839-15840\">AL</span>"+
564 " </span>"+
565 " </span>"+
566 " <span xlink:show=\"other\" data-action=\"join\" xlink:href=\"#token-WDD17/982/72848-p15839-15840\">"+
567 ":"+
568 " <span xml:id=\"token-WDD17/982/72848-p15840-15846\">"+
569 " <span xml:id=\"token-WDD17/982/72848-p15840\">"+
570 " <span xlink:title=\"lwc/d:--\" xlink:show=\"none\" xlink:href=\"#token-WDD17/982/72848-p15840-15846\">halt</span>"+
571 " </span>"+
572 " </span>"+
573 " </span>"+
574 " <span xlink:show=\"other\" data-action=\"join\" xlink:href=\"#token-WDD17/982/72848-p15840-15846\">"+
575 " "+
576 " <span xlink:title=\"lwc/d:NK\" xlink:show=\"none\" xlink:href=\"#token-WDD17/982/72848-p15842\">den</span>"+
577 " "+
578 " <span xml:id=\"token-WDD17/982/72848-p15842\">"+
579 " <span xlink:title=\"lwc/d:OA\" xlink:show=\"none\" xlink:href=\"#token-WDD17/982/72848-p15843\">Ball</span>"+
580 " </span>"+
581 " "+
582 " <span xml:id=\"token-WDD17/982/72848-p15843\">"+
583 " <span xlink:title=\"lwc/d:PD\" xlink:show=\"none\" xlink:href=\"#token-WDD17/982/72848-p15840\">flach</span>"+
584 " </span>"+
585 ", "+
586 " <mark>"+
587 " <span xlink:title=\"lwc/d:MO\" xlink:show=\"none\" xlink:href=\"#token-WDD17/982/72848-p15845\">ganz</span>"+
588 " "+
589 " <span xml:id=\"token-WDD17/982/72848-p15845\">"+
590 " <span xlink:title=\"lwc/d:CJ\" xlink:show=\"none\" xlink:href=\"#token-WDD17/982/72848-p15843\">flach</span>"+
591 " </span>"+
592 " </mark>"+
593 " </span>"+
594 "</span>"+
595 "<span class=\"context-right\"></span>";
596
Akron0ad7cd22018-02-08 18:03:06 +0100597 var meta = {"messages":[["Response format is temporary"]],"@context":"http://korap.ids-mannheim.de/ns/KoralQuery/v0.3/context.jsonld","meta":{},"document":{"@type":"koral:document","fields":[{"@type":"koral:field","type":"type:store","key":"ref","value":"My reference"},{"@type":"koral:field","type":"type:text","key":"title","value":"Der Name der Rose"},{"@type":"koral:field","type":"type:string","key":"textSigle","value":"a/b/c"},{"@type":"koral:field","type":"type:string","key":"keyword","value":["baum","wald"]},{"@type":"koral:field","type":"type:number","key":"zahl1","value":56},{"@type":"koral:field","type":"type:string","key":"name","value":"Peter"}]}};
598
Akronbf3fc9d2018-03-08 12:36:39 +0100599 meta = {"messages":[["Response format is temporary"]],"@context":"http://korap.ids-mannheim.de/ns/KoralQuery/v0.3/context.jsonld","meta":{},"document":{"@type":"koral:document","fields":[{"@type":"koral:field","type":"type:number","key":"pubDate","value":20170701},{"@type":"koral:field","type":"type:string","key":"textSigle","value":"WDD17/982/72848"},{"@type":"koral:field","type":"type:string","key":"foundries","value":"dereko dereko/structure dereko/structure/base-sentences-paragraphs-pagebreaks lwc lwc/dependency treetagger treetagger/morpho"},{"@type":"koral:field","type":"type:string","key":"corpusSigle","value":"WDD17"},{"@type":"koral:field","type":"type:string","key":"docSigle","value":"WDD17/982"},{"@type":"koral:field","type":"type:store","key":"reference","value":"Diskussion:99 Namen Allahs/Archiv/1, In: Wikipedia - URL:http://de.wikipedia.org/wiki/Diskussion:99_Namen_Allahs/Archiv/1: Wikipedia, 2017"},{"@type":"koral:field","type":"type:text","key":"author","value":"ArchivBot, u.a."},{"@type":"koral:field","type":"type:number","key":"creationDate","value":20140609},{"@type":"koral:field","type":"type:string","key":"textTypeArt","value":"Diskussion"},{"@type":"koral:field","type":"type:store","key":"editor","value":"wikipedia.org"},{"@type":"koral:field","type":"type:text","key":"title","value":"Diskussion:99 Namen Allahs/Archiv/1"},{"@type":"koral:field","type":"type:store","key":"tokenSource","value":"base#tokens"},{"@type":"koral:field","type":"type:store","key":"layerInfos","value":"dereko/s=spans lwc/d=rels tt/l=tokens tt/p=tokens"},{"@type":"koral:field","type":"type:string","key":"textClass","value":"staat-gesellschaft biographien-interviews"},{"@type":"koral:field","type":"type:string","key":"availability","value":"CC-BY-SA"}]}};
Akron0ad7cd22018-02-08 18:03:06 +0100600
Akronbf3fc9d2018-03-08 12:36:39 +0100601 meta = {
602 "@context":"http:\/\/korap.ids-mannheim.de\/ns\/KoralQuery\/v0.3\/context.jsonld",
603 "document":{
604 "@type":"koral:document",
605 "fields":[
606 {
607 "@type":"koral:field",
608 "key":"editor",
609 "type":"type:store",
610 "value":"wikipedia.org"
611 },
612 {
613 "@type":"koral:field",
614 "key":"textSigle",
615 "type":"type:string",
616 "value":"WPD15\/264\/58336"
617 },
618 {
619 "@type":"koral:field",
620 "key":"author",
621 "type":"type:text",
622 "value":"Sprachpfleger, u.a."
623 },
624 {
625 "@type":"koral:field",
626 "key":"docSigle",
627 "type":"type:string",
628 "value":"WPD15\/264"
629 },
630 {
631 "@type":"koral:field",
632 "key":"textTypeArt",
633 "type":"type:string",
634 "value":"Enzyklopädie-Artikel"
635 },
636 {
637 "@type":"koral:field",
638 "key":"language",
639 "type":"type:string",
640 "value":"de"
641 },
642 {
643 "@type":"koral:field",
Akrona0ea3c32018-12-14 18:33:48 +0100644 "key":"link",
645 "type":"type:attachement",
646 "value":"data:application/x.korap-link;title=Wikipedia,https://de.wikipedia.org/wiki/Beispiel"
647 },
648 {
649 "@type":"koral:field",
Akronbf3fc9d2018-03-08 12:36:39 +0100650 "key":"docTitle",
651 "type":"type:text",
652 "value":"Wikipedia, Artikel mit Anfangszahl 2, Teil 64"
653 },
654 {
655 "@type":"koral:field",
656 "key":"textType",
657 "type":"type:string",
658 "value":"Enzyklopädie"
659 },
660 {
661 "@type":"koral:field",
662 "key":"availability",
663 "type":"type:string",
664 "value":"CC-BY-SA"
665 },
666 {
667 "@type":"koral:field",
668 "key":"foundries",
669 "type":"type:keywords",
670 "value":[
671 "corenlp",
672 "corenlp\/constituency",
673 "corenlp\/morpho",
674 "corenlp\/sentences",
675 "dereko",
676 "dereko\/structure",
677 "dereko\/structure\/base-sentences-paragraphs-pagebreaks",
678 "opennlp",
679 "opennlp\/morpho",
680 "opennlp\/sentences"
681 ]
682 },
683 {
684 "@type":"koral:field",
685 "key":"creationDate",
686 "type":"type:date",
687 "value":"2015-04-17"
688 },
689 {
690 "@type":"koral:field",
691 "key":"title",
692 "type":"type:text",
693 "value":"22:43 – Das Schicksal hat einen Plan"
694 },
695 {
696 "@type":"koral:field",
697 "key":"pubDate",
698 "type":"type:date",
699 "value":"2015-05-01"
700 },
701 {
702 "@type":"koral:field",
703 "key":"reference",
704 "type":"type:store",
705 "value":"22:43 – Das Schicksal hat einen Plan, In: Wikipedia - URL:http:\/\/de.wikipedia.org\/wiki\/22:43_–_Das_Schicksal_hat_einen_Plan: Wikipedia, 2015"
706 },
707 {
708 "@type":"koral:field",
709 "key":"textClass",
710 "type":"type:keywords",
711 "value":["kultur","film"]
712 },
713 {
714 "@type":"koral:field",
715 "key":"tokenSource",
716 "type":"type:store",
717 "value":"base#tokens"
718 },
719 {
720 "@type":"koral:field",
721 "key":"publisher",
722 "type":"type:store",
723 "value":"Wikipedia"
724 },
725 {
726 "@type":"koral:field",
727 "key":"layerInfos",
728 "type":"type:store",
729 "value":"corenlp\/c=spans corenlp\/p=tokens corenlp\/s=spans dereko\/s=spans opennlp\/p=tokens opennlp\/s=spans"
730 },
731 {
732 "@type":"koral:field",
733 "key":"pubPlace",
734 "type":"type:string",
735 "value":"URL:http:\/\/de.wikipedia.org"
736 },
737 {
738 "@type":"koral:field",
739 "key":"corpusTitle",
740 "type":"type:text",
741 "value":"Wikipedia"
742 },
743 {
744 "@type":"koral:field",
745 "key":"corpusEditor",
746 "type":"type:store",
747 "value":"wikipedia.org"
748 },
749 {
750 "@type":"koral:field",
751 "key":"corpusSigle",
752 "type":"type:string",
753 "value":"WPD15"
754 }
755 ]
756 }
757 };
Akron0ad7cd22018-02-08 18:03:06 +0100758
Nils Diewald4347ee92015-05-04 20:32:48 +0000759
Nils Diewald0e6992a2015-04-14 20:13:52 +0000760 KorAP.API.getMatchInfo = function(match, callObj, cb) {
Akron7f613e02016-11-07 02:50:44 +0100761 console.dir(callObj);
Nils Diewald0e6992a2015-04-14 20:13:52 +0000762 if (callObj["spans"] !== undefined && callObj["spans"] === true) {
Akronaa01dca2018-02-05 19:51:28 +0100763 if (callObj["layer"] === "d") {
764 return cb({ "snippet": relSnippet });
765 }
766 else {
767 return cb({ "snippet": treeSnippet });
768 }
Nils Diewald0e6992a2015-04-14 20:13:52 +0000769 }
770 else {
771 return cb({ "snippet": snippet });
772 }
773 };
Akron0ad7cd22018-02-08 18:03:06 +0100774
775 KorAP.API.getTextInfo = function(doc, callObj, cb) {
776 return cb(meta);
777 };
Nils Diewald0e6992a2015-04-14 20:13:52 +0000778});