You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note that this style seems to survive a round-trip from PROV-O via PROV-XML over to PROV-O again.
Obviously we can blame the PROV-Dictionary spec for not implementing it in this PROV-O style also in PROV-XML and PROV-N (which would then have been backwards compatible to all PROV syntaxes)
This issue however asks for some prov.py API support for making PROV-Dictionary statements across all syntaxes.
It might ideally need some hacks to have consistent serialization and parsing though - but as a first attempt I would suggest adding support for our approach as it would not cause issues in loading/saving. Also I think the implication of a Dictionary being a Collection should be implied for compatibility with consumers not understanding PROV-Dictionary, but I understand if that can be harder to maintain in a mutable prov model in memory (e.g. there could be multiple keys having same value).
The text was updated successfully, but these errors were encountered:
We've been wanting to use PROV-Dictionary extension with prov.py, but it's a bit tricky if we want to serialize in multiple formats.
Our current workaround is to register the regular membership of
prov:Collection
as supported by prov.py, and also say it's a prov:Dictionary:Then regular membership is easy:
prov.py does however not have a
dictionaryMembership
method. To express the PROV Dictionary we use a PROV-O compatible attributes:This workaround produces PROV-O statements correct according to PROV-Dictionary section 5:
However the PROV-N output does not match PROV-Dictionary section 4:
If this was supported the membership should come in PROV-N as:
Is there a way to add such name-spaced statements to PROV-N with prov.py?
Similarly expressed in PROV-XML according to PROV-Dictionary section 6 we would expect something like:
but with our workaround we get:
Note that this style seems to survive a round-trip from PROV-O via PROV-XML over to PROV-O again.
Obviously we can blame the PROV-Dictionary spec for not implementing it in this PROV-O style also in PROV-XML and PROV-N (which would then have been backwards compatible to all PROV syntaxes)
This issue however asks for some prov.py API support for making PROV-Dictionary statements across all syntaxes.
It might ideally need some hacks to have consistent serialization and parsing though - but as a first attempt I would suggest adding support for our approach as it would not cause issues in loading/saving. Also I think the implication of a Dictionary being a Collection should be implied for compatibility with consumers not understanding PROV-Dictionary, but I understand if that can be harder to maintain in a mutable prov model in memory (e.g. there could be multiple keys having same value).
The text was updated successfully, but these errors were encountered: