Both sides previous revisionPrevious revisionNext revision | Previous revision |
en:pojmy:syntakticka_analyza [2020/12/17 11:58] – [Automatic syntactic annotation: parsing] tomasjelinek | en:pojmy:syntakticka_analyza [2022/08/13 13:08] (current) – [Syntactic analysis and syntactic tagging] alexandrrosen |
---|
====== Syntactic analysis and syntactic tagging ====== | ====== Syntactic analysis and syntactic tagging ====== |
| |
Some of CNC corpora (the first of which is [[en:cnk:syn2015|SYN2015]]) are syntactically annotated, marking dependency relations between two words in a sentence and the analytical functions of individual words. This syntactic annotation is based on the principles of the analytical-layer annotation used in the [[http://ufal.mff.cuni.cz/pdt2.0/index-cz.html|Prague Dependency Treebank]] (PDT). | Some of CNC corpora (the first of which is [[en:cnk:syn2015|SYN2015]]) are syntactically annotated, marking dependency relations between two words in a sentence and the analytical functions of individual words. This syntactic annotation is based on the principles of the analytical-layer annotation used in the [[http://ufal.mff.cuni.cz/pdt2.0/index-cz.html|Prague Dependency Treebank]] (PDT). The [[en:cnk:intercorp|InterCorp]] parallel corpus in its release [[en:cnk:intercorp:verze13ud|13ud]] is syntactically (and also morphologically) annotated in an alternative way, following the guidelines of the international [[en:pojmy:ud|Universal Dependencies]] project. |
| |
===== The system of syntactic annotation: the analytical layer of the Prague Dependency Treebank ===== | ===== The system of syntactic annotation: the analytical layer of the Prague Dependency Treebank ===== |
| |
Syntactic annotation is done automatically, using a syntactic ([[en:pojmy:parser|parser]]). For the annotation of the SYN2015 corpus, the TurboParser was used, for SYN2020, a "neural" parser of the NeuroNLP2 tools was used. This kind of annotation has a higher error rate than [[en:pojmy:morfologicka_analyza|morphological annotation]]. In SYN2020, more than 1/9 [[en:pojmy:token|tokens]] are left without a correctly identified „parent“ or correctly matched syntactic function, in SYN2015, it's as much as 1/6 of [[en:pojmy:token|tokens]].\\ | Syntactic annotation is done automatically, using a syntactic ([[en:pojmy:parser|parser]]). For the annotation of the SYN2015 corpus, the TurboParser was used, for SYN2020, a "neural" parser of the NeuroNLP2 tools was used. This kind of annotation has a higher error rate than [[en:pojmy:morfologicka_analyza|morphological annotation]]. In SYN2020, more than 1/9 [[en:pojmy:token|tokens]] are left without a correctly identified „parent“ or correctly matched syntactic function, in SYN2015, it's as much as 1/6 of [[en:pojmy:token|tokens]].\\ |
The success rate of parsing is measured as UAS (unlabeled attachment score), the rate of successful parent identification and LAS (labeled attachment score), the rate of successful identification of both parent and syntactic function. In the SYN2015 and SYN2020, these rates are as follows: | The success rate of parsing is measured as UAS (unlabeled attachment score), the rate of successful parent identification, and LAS (labeled attachment score), the rate of successful identification of both parent and syntactic function. In the SYN2015 and SYN2020, these rates are as follows: |
| |
^ korpus ^ UAS ^ LAS^ | ^ korpus ^ UAS ^ LAS^ |
| |
| |
Therefore, although syntactic annotation can be used as an **approximate guide for further language research**, we must keep in mind that it is not entirely reliable. The error rate is higher for less common syntactic functions and constructions, whereas the most frequent functions in expected contexts have an error rate lower than 10%. | Therefore, although syntactic annotation can be used as an **approximate guide for further language research**, we must keep in mind that it is not entirely reliable. The error rate is higher for less common syntactic functions and constructions, whereas the most frequent functions in expected contexts have an error rate lower than 5% (SYN2020) or 10% (SYN2015). |
| |
[{{ :pojmy:mf041122_color.jpg?400|}}] | [{{ :pojmy:mf041122_color.jpg?400|}}] |
| |
The technical root of the dependency tree (top left, with the sentence identifier) governs the predicate //převážet// (Pred) and final punctuation mark (AuxK). The predicate governs the subject //Plavidlo// (Sb) and object //turisty// (Obj). The auxiliary verb //bude// (AuxV) forms one verbal unit with the verb //převážet//, and it is therefore also depicted as being dependent on this node. Furthermore, the verb //převážet// also governs the coordinated prepositional phrase with a locative adverbial function// mezi minaretem a zříceninou Janohrad//. In PDT, on the level of surface syntax the preposition's function is to formally govern, so the verb //převážet// governs the preposition (AuxP), which in turn governs the representative of the coordinating relation, the conjunction //a// (Coord). Both coordinated nouns from the prepositional phrase //minaretem a zříceninou// are dependent on the coordination node (Adv_Co: Adv, i.e. adverbial function, is furnished with an additional component _Co, which indicates coordinated members). The noun //zříceninou// is further modified by the incongruent attribute //Janohrad// (Atr). The coordinating node (Coord) also governs the prepositional phrase //v parku//, which itself is not coordinated, but modifies both members of the coordination, i.e. both the word //minaretem// and the word //zříceninou//. Again, the preposition //v// (AuxP) is dependent on the governing member, and the noun //parku// with the attributive function (Atr) is in turn dependent on the preposition. | The technical root of the dependency tree (top left, with the sentence identifier) governs the predicate //převážet// (Pred) and final punctuation mark (AuxK). The predicate governs the subject //Plavidlo// (Sb) and object //turisty// (Obj). The auxiliary verb //bude// (AuxV) forms one verbal unit with the verb //převážet//, and it is therefore also depicted as being dependent on this node. Furthermore, the verb //převážet// also governs the coordinated prepositional phrase with a locative adverbial function// mezi minaretem a zříceninou Janohrad//. In PDT, on the level of surface syntax the preposition's function is to formally govern, so the verb //převážet// governs the preposition (AuxP), which in turn governs the representative of the coordinating relation, the conjunction //a// (Coord). Both coordinated nouns from the prepositional phrase //minaretem a zříceninou// are dependent on the coordination node (Adv_Co: Adv, i.e. adverbial function, is furnished with an additional component _Co, which indicates coordinated members). The noun //zříceninou// is further modified by the incongruent attribute //Janohrad// (Atr). The coordinating node (Coord) also governs the prepositional phrase //v parku//, which itself is not coordinated, but modifies both members of the coordination, i.e. both the word //minaretem// and the word //zříceninou//. Again, the preposition //v// (AuxP) is dependent on the governing member, and the noun //parku// with the attributive function (Atr) is in turn dependent on the preposition. |
| |
| ===== Visualisation of syntactic structures in KonText ===== |
| |
| For every sentence in a syntactically annotated corpus (currently [[en:cnk:syn2015|SYN2015]] and [[en:cnk:syn2020|SYN2020]]), a syntactic structure can be visualised by clicking on a little icon representing a syntactic tree on the left side of a concordance line (marked with a red circle in the following image):\\ |
| |
| {{:pojmy:zobrazenisyntaxe.png?500|Syntactic structure visualisation}}\\ |
| |
| By clicking on the icon, a representation of the syntactic structure is displayed (a syntactic tree). The left-to-right order in the syntactic representation corresponds to the order in the sentence, the dependent tokens are placed below the governing tokens. The following image represents the structure of a subordinate clause from the SYN2020 corpus "//aby ses měla nač vymluvit//" [so that you can find an excuse]. The sentence contains three so called [[en:cnk:syn2020:agregat|agreggates]], i.e. tokens containing two or more syntactic words:\\ |
| |
| {{:cnk:syn2020:agregaty_syntax.png?250|Example of syntactic structure in Kontext}}\\ |
| |
===== Searching KonText for syntactic structures: syntactic attributes ===== | ===== Searching KonText for syntactic structures: syntactic attributes ===== |
| |
Searching in syntactically annotated corpora typically requires an interface specially designed to display the syntactic structure, for example the program [[https://ufal.mff.cuni.cz/tred/|TrEd]]. The [[en:manualy:kontext:index|KonText]] interface does not offer the option of viewing the syntactic structure, nonetheless it is possible to search for words and phrases according to syntactic parameters. For this purpose, each token is assigned several [[en:pojmy:atributy_pozicni|attributes]], in addition to the smaller number of attributes which are assigned only to selected tokens. All syntactic attributes are described in a [[en:seznamy:syntakticke_znacky|separate entry]]. The basic syntactic attributes assigned to all tokens are: | It is possible to formulate queries in KonText based on syntactic properties of words. For this purpose, each token is assigned several [[en:pojmy:atributy_pozicni|attributes]]. All syntactic attributes are described in a [[en:seznamy:syntakticke_znacky|separate entry]]. The basic syntactic attributes assigned to all tokens are: |
* [[en:seznamy:parent|parent]] (numbered reference to the position of the governing token) | * [[en:seznamy:parent|parent]] (numbered reference to the position of the governing token) |
* [[en:seznamy:afun|afun]] (syntactic function) | * [[en:seznamy:afun|afun]] (syntactic function) |