Skip to content

Log sources and history of derivations and lexemes #3

@vidraj

Description

@vidraj

The old Perl API logged derivation history and remembered which module and which annotation file was responsible for each derivational link. This is very useful when debugging – if you see an error in the database, you can quickly trace it to its source by looking at the history.

It is also theoretically useful for identifying homonyms – we can use the derivation history to find lexemes that have multilple legitimate parents, without complicating the API by relaxing the 'single parent' restriction. These can be dual paths or homonyms.

The Python API lacks this capability so far, but it should be added.

Ideally, we would track the following for each link:

  • the linked lexeme
  • the module that created the link
  • the file where the link was found (if applicable, some modules don't need/use annotations)
  • the line number where the link was found (ditto)
  • maybe also the exact line / paragraph for easy grepping

and remember the whole history of these informations.

Lexeme and module information can be obtained automatically, because the pipeline manager knows the linked lexeme and which module is currently running. The file and line information probably has to be provided by the modules.

The Perl API also remembered lexeme creators in the same way. Lexemes can come from MorfFlex, extra annotations or specific modules and we want to distinguish these sources.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions