Found this repo, where it seems the text engine data is explained, with examples.
Written in Ruby, but there’s explanations with examples, and Ruby code seems as simple as python to understand… (but didn’t dig more than just an eye on code)
If it can help for one day, allows Krita to read text part in psd file (at least, keep link to repo in bookmarks )
Grum999