monarch-initiative / koza

Data transformation framework for LinkML data models
https://koza.monarchinitiative.org/
BSD 3-Clause "New" or "Revised" License
47 stars 4 forks source link

Add SSSOM sssupport #108

Closed kevinschaper closed 10 months ago

kevinschaper commented 1 year ago

Let's do our mapping with Koza.

We need to leave the original mapping support code available, since it's

Config changes:

SSSOM reader:

SSSOM utils:

kgx writer:

Note: I had been thinking of writing both un-mapped output and separately write the mapped files, but that feels like kind of a waste of space, since you can (fairly) easily rewind the mapping logic

matentzn commented 1 year ago

sssupport.

🐍

Is this about rewiring at ingest time?

kevinschaper commented 1 year ago

@matentzn yeah, I wasn't sure if it should happen in koza, kgx, or a standalone tool and I got excited about koza support because we don't need to iterate over all the rows a second time.

(Plus also that ideally koza and kgx should probably both be able to rewire based on a sssom file/df)

matentzn commented 1 year ago

OK cool. So the rewire code will leave in a single module that is shared by both tools, or will this be duplicated? I would be interested to review that code once it is there, just so you know if you would like another pair of eyes on it!

sierra-moxon commented 1 year ago

KGX has a SSSOM source written by @hrshdhgd https://github.com/biolink/kgx/blob/master/kgx/source/sssom_source.py

kevinschaper commented 1 year ago

Is that for applying mappings to rewire edges or transforming the SSSOM itself into other formats?

hrshdhgd commented 1 year ago

I don't recall writing this code.

glass-ships commented 1 year ago

see #109