IEMLdev / ieml

IEML semantic language - a meaning-representation system based on semantic primitives and a regular grammar. Basic semantic relationships between concepts are automatically computed from syntactic similarities.
https://dev.intlekt.io/
GNU General Public License v3.0
53 stars 6 forks source link

Freeing Terms.__dict__ when their are used by usls when switching dictionary #42

Closed ogrergo closed 7 years ago

ogrergo commented 7 years ago

Only one version of the dictionary can live in memory, when switching versions, the old terms are released to free memory. But they can be used by a Morphem in a usl and raise an exception.

Possible fix: make the terms "Global" objects with a mapping {dictionaryVersion -> {script, translation, relations, index, ...}. This allows multiples versions of the dictionary to live in memory and share the same pool of terms. The translation of an usl between differents versions is then implicit.