[CWB] Structural attributes in aligned languages

Stefan Evert stefanML at collocations.de
Tue Mar 24 09:19:49 CET 2015


> No, I'd like to display the meta data. I convert sgml to xml and then use xslt to display the metadata.

That's not possible in CQP, I'm afraid. The easiest solution would be to write a Perl script using the CWB::CL module, which takes the list of matches, finds the corresponding regions in the aligned corpus, and prints the relevant metadata.

At some point I harboured the idea of implementing a "translate" command in CQP, which maps a named query result to an aligned corpus, so you can run arbitrary subqueries in the other corpus, have better control over display of aligned regions, and access metadata.  Of course, you still would have to stitch the output for the source corpus and the aligned regions together yourself.

I never got around to doing this because such a translate operation involves quite a lot of housekeeping, but if people feel this would be useful Andrew or I can take another look at it.

Cheers,
Stefan



More information about the CWB mailing list