spraakbanken / korp-frontend

Frontend for Korp, a tool using the IMS Open Corpus Workbench (CWB).
https://spraakbanken.gu.se/en/tools/korp
MIT License
16 stars 8 forks source link

No map for advanced CQP expressions that CQPParser does not recognize #212

Open janiemi opened 3 years ago

janiemi commented 3 years ago

If a CQP expression in the advanced search contains constructs that Korp’s CQPParser does not recognize, you cannot get a map based on the search results: for example, labels and global constraints, such as a:[] b:[] :: a.word = b.word, or [lbound(text)]. (I know the latter could also be expressed as <text> [].)

This would seem to be due to expanding CQP operators in showMap of statsResultCtrl. Even though CQPParser could certainly be extended to handle more CQP constructs, I’m wondering if CQP operators need to be expanded in advanced search expressions.

majsan commented 2 years ago

They do not, since the whole expansion thing is just for saving the state of the operator in the extended search (I think). So there is no reason not to fix it.