Open alanruttenberg opened 3 years ago
hey @alanruttenberg
For your point 2. have you tried --labels true
? (https://robot.obolibrary.org/diff)
Re 1. Would be super useful, I agree, but its not easy to implement. I think @jamesaoverton and @cmungall are working on something called an ontology change language that could describe changes like this formally.
Re 3. I think it really depends on the use case - I for one use the Declarations to understand which terms have been added/removed etc between two versions of an ontology, but I agree, in 90% of the cases this is noise. It would be sort of cool if the --axioms
selector in robot remove
could be used to control which axiom types I want to see in the diff..
Hi @alanruttenberg. Note that ROBOT relies on owl-diff for most diff functionality. We are very strict about backwards compatibility, so while we often add new functionality, we do not change existing behaviour or defaults except to fix bugs. Admittedly, this can be annoying when we now have better ideas for how things should be done, but I believe that it's far more annoying to break existing systems and workflows.
I'd be happy for ROBOT diff to support more formats. The current feature set meets all my needs for my projects, so I can't prioritize developing new diff features, but PRs would be appreciated.
For friendlier views of changes, please try the "pretty", HTML and Markdown formats. As @matentzn mentioned, @cmungall has designed a knowledge graph change language that the Knocean team is currently implementing, and that may be a good alternative in the future.
As Nico mentioned, the --labels true
option and other formats should address this point. Only the default "plain" format uses raw IRIs, for fastest performance and historical reasons.
It's true that the Declarations are usually not very informative, but completeness seems very important to me, and your workaround is straightforward. I think that the HTML and Markdown formats also mitigate the noise.
The HTML and Markdown formats use Manchester with labels and links, like Protege.
hey @alanruttenberg
For your point 2. have you tried
--labels true
? (https://robot.obolibrary.org/diff)
Just did. Thanks. It's better but still noisy.
Re 1. Would be super useful, I agree, but its not easy to implement. I think @jamesaoverton and @cmungall are working on something called an ontology change language that could describe changes like this formally.
It might be hard for general axioms, but request was for properties. For (Annotation|Object|Data)PropertyAssertion the second 'argument' is the subject, the term you would check for sameness.
Re: ontology change language, I had a glance at knowledge graph change language. I'm not so up on knowledge graphs. It wasn't clear whether it handled plain ontology diffs.
I think the kgcl will cover these cases that you are talking about; I would wait for that. Inferring changes from additions and removals is a bit non-deterministic (see example 1 below), but I think it would be super useful as you are saying. In the meantime, I would suggest to follow @jamesaoverton suggestion and use the markdown/html outputs which sort the diff in a way that almost looks like its describing a change.
- :a :b :c
+ :a :b :d
+ :a :b :e
Currently, if the value of a property changes, there are two lines shown and they are in different sections - one a "-" and later one a "+". It would be nice if there were 3 sections: lost (-), gained(+) and changed, where for the changed items the name of the IRI/label is shown once, followed by the two values indicating before(-) and after(+).
It is difficult to read the diff when the opaque IRIs are shown. It would be nice to have an option to substitute, in the assertions, the label rather than the IRI. This isn't syntactically correct functional syntax, but then it isn't a typical use to copy-paste the functional syntax from the diff into an ontology. There could be a list of label properties to try, in order, by default rdfs:label and skos:prefLabel (others?).
Perhaps it differs for other people, but the declarations are just noise when I'm reading the diffs. It would be nice to be able to suppress them even though it is easy enough to do on the command line with | grep -v '[+-] Declaration' . It would be interesting to hear from others whether skipping them is a reasonable default. That would be my preference.
It would be nice to be able to select the syntax that is used to print the assertions. I'm partial to Manchester using labels, as is displayed in Protégé.