Introduce directionality to mappings #319
jsstevenson
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Two broad goals
translationandtranscriptionThe current state
Mappingconsists of asource_id, adest<ination>_id, and aMappingType, whereMappingTypecan be"liftover","transcription", and"translation". (i.e. undirected).get_mappings()method takes asource_idas an arg, and retrieves all mappings whereMapping.source_idmatches that. Which means...Mapping, you need to write that mapping twice, flipping source and destination. And directionality of the relationship is not preserved.A few stray ideas (maybe mix and match from these)
MappingTypeenum values totranscribes_toandtranslates_to, and changeAnyVar.get_mappings()to accept args forsource_id,dest_id(+ maybe an "either" operator?)MappingTypeenum to includetranscribes_from,transcribes_to,translates_from, andtranslates_to. When appropriate, or at the request of the user, theAnyVar.put_mapping()method should write both directions at once so a user doesn't have to call it twiceBeta Was this translation helpful? Give feedback.
All reactions