Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lack of a Good Editor #35

Open
dbooth-boston opened this issue Dec 10, 2018 · 36 comments
Open

Lack of a Good Editor #35

dbooth-boston opened this issue Dec 10, 2018 · 36 comments
Labels
Category: tools For RDF tools primarily-tools Tool makers should address this

Comments

@dbooth-boston
Copy link
Collaborator

'Recently both Atom and Visual Studio Code have both come to the
mainstream. While there are many plugins that will do automatic code
completion for you in Javascript, Java, etc. There is none out there
that will do that for you in Turtle."
https://lists.w3.org/Archives/Public/semantic-web/2018Dec/0088.html

@dbooth-boston dbooth-boston added the Category: tools For RDF tools label Dec 10, 2018
@william-vw
Copy link

Perhaps this could solve the up-front dataset authoring cost to an extent - an editor, loaded with known predicates and types, that supports a sort of auto-complete while authoring RDF?

@draggett
Copy link
Member

Another approach would be to focus on easier editing tools at a higher level than the RDF core. A higher level framework would embody richer knowledge that editing tools could exploit to simplify authoring, e.g. expanding and collapsing level of detail at meaningful semantic boundaries, tabular controls for property/value sets, n-ary chunks and so forth.

@william-vw
Copy link

william-vw commented Dec 10, 2018 via email

@jeff-zucker
Copy link

Please take a look at https://github.com/jeff-zucker/solid-ide - it uses the Ace/Cloud9 editor to explore Solid data stores. I'd value feedback and suggestions to move it towards the kinds of things you are talking about here.

@ktk
Copy link

ktk commented Dec 18, 2018

FYI we are experimenting with DSL frameworks for doing that. Currently I create R2RML mappings out of a DSL environment in Eclipse (Xtext). Benefit of DSL frameworks is that it takes care of a hell lot of stuff that would be a lot of work to implement on its own.

Most IDEs nowadays support the Language Server protocol protocol. Xtext can act as a LSP server so once we have a proper implementation there it should work on pretty much every IDE (given that you run the server as well or use it as a service). We experiment with creating Turtle as well in xtext with completion for vocabs & many other nice things.

Again the drawback is that you will need an xtext instance bu the benefit is that you implement the work once and will be able to use it in every editor that supports LSP. At least that is what LSP claims, we plan to see how well this works already. In my opinion this is the way to go for creating/maintaining RDF in some manual form. Which is surely not always the right way to go.

@jeff-zucker
Copy link

Thanks for the information. My project is less ambitious and probably no help to yours. I agree that manually maintaining RDF is not the way to go for most things. My target audience is those unfamiliar with RDF who just need to see what it looks like and see what happens to it when they make minor changes it. For that audience, things like auto-completion might be more confusing than helpful, depending on how they are implemented.

@draggett
Copy link
Member

@darth-willy wrote

Higher-level – would you mean up to the ontology level or still RDF-specific (syntactic) features such as different views (e.g., tabular) on RDF data?

I have some ideas of my own, but really want to hear from industry developers as to what use cases, challenges and ideas would best help them. How to reach that far, though?

Current ontology tools are hard to work with - what would ease that? Perhaps better visualisation and browsing tools? Perhaps easier rule languages to work with given ontologies?

I've also been thinking about ideas for automatic induction and maintenance of ontologies from curated collections of examples and counter examples. Such a framework would also be designed to ease maintenance of rule bases to keep them in sync as the ontology evolves to match changing needs. In this sense, AI has plenty of potential to amplify human effort.

@draggett
Copy link
Member

draggett commented Dec 19, 2018

A related idea is to see how far we can go with using natural language for both data and rules. This assumes a graph representation that is close to the way words are used in natural language, rather than a deeper logical representation which is problematic given the looseness of natural language. It also runs counter to current practice of applying deep learning to natural language with no attempt to represent meaning except in a very limited and superficial way. One way to use natural language is as the input for machine learning of ontologies and rules. This can involve constraints on the grammar and scope for more robust processing, together with conventions for mapping natural language terms into those needed for the learned ontology.

@william-vw
Copy link

Yes, it would be highly useful to bootstrap the creation of ontologies and rules based on unstructured data (if that's what you meant). I quite appreciate Protege to work with ontologies (my main issue is that it's essentially the only ontology tool out there, afaik).

A solution could be, in analogy to the inference support, extend Protege with API support for creating ontology classes and rules, thus allowing third parties to create plugins.

For instance, to mine association rules, a solution could be to plugin the ML layer of the SANSA stack system (?)

It's true that, while Protege supports a nice (imo) editor for creating rules, it falls short when managing more than a few rules. I've done some simple work on improving its capacity for rule management - I was planning on generating a pull request after the semester.

@namedgraph
Copy link

Would anyone be willing to pay for a good editor or is open-source assumed here? :) We have the technology, it's just not where our focus is currently.

@william-vw
Copy link

Would anyone be willing to pay for a good editor or is open-source assumed here? :)

So either be prepared to pay for a good ontology editor, or move along (peasant)? I understand where it comes from but I don't think that's a very useful attitude.

We have the technology, it's just not where our focus is currently.

I'm sure you / we do, but operationalizing that technology is another issue. I am simply communicating a need that I (as a practitioner) have experienced, and my thoughts and efforts on filling that need.

Note that creating and maintaining ontologies is the only Semantic Web application that I've seen in university curricula (aside from niche courses on RDF) - such as knowledge management in health informatics, and data management in the school of information management.

@namedgraph
Copy link

What is a useful attitude then? (I'm not here to troll). My point is that commercial software comes with expectations like quality, maturity and support. Is that not part of operationalizing?
Would you expect to use a triplestore such as Stardog or Virtuoso for free as well?

Most of SW frameworks are currently open-source. Some are mature, such as RDF4J, Jena, librdf etc. But it took them 15-20 years to get there (!!!). Maybe the UX tools are just following the same timeline?

@cyocum
Copy link

cyocum commented Dec 19, 2018

Would anyone be willing to pay for a good editor or is open-source assumed here? :)

So either be prepared to pay for a good ontology editor, or move along (peasant)? I understand where it comes from but I don't think that's a very useful attitude.

When I wrote this, I did not have an ontology editor in mind. I wanted a general RDF editor which would have tab completes for predicates based on prefixes and things that my collaborators and I needed to create RDF data. Basically, my project we had create TRiG files which represent genealogies in early Irish. We have a few automated ways of creating parts of RDF/TRiG files but we need people to read and translate Old/Middle Irish into RDF/TRiG. So, I would love an editor (Eclipse, IntelliJ, Visual Basic Code, Atom, whatever) which can help them make the format correct and generally tell them when it is wrong and suggest predicates based on prefixes. Just like an IDE would normally do for programming languages.

We have the technology, it's just not where our focus is currently.

I'm sure you / we do, but operationalizing that technology is another issue. I am simply communicating a need that I (as a practitioner) have experienced, and my thoughts and efforts on filling that need.

Note that creating and maintaining ontologies is the only Semantic Web application that I've seen in university curricula (aside from niche courses on RDF) - such as knowledge management in health informatics, and data management in the school of information management.

I come from a Humanities/Software Engineering background and many Humanities data sets are human curated and maintained. From the small slice of the Digital Humanities that I am aware of, a good RDF data editor would be great and give people feedback faster on syntactic correctness, etc.

I also believe this would have wider benefits for people coming to RDF from other programming languages so they have same support for the RDF Serializations in their editors that they have for their programming languages. I have used Protege in the past and it is fine as far as I can tell for editing ontologies (Tbox) but it is not for editing data files (Abox).

@william-vw
Copy link

william-vw commented Dec 19, 2018

We're talking about ways to improve current (ontology) editing tools to suit practitioner needs - merely waiving your hand at that effort by saying "well, pay for it then" doesn't seem to contribute anything.

Also, who would I be paying? In lieu of such an alternative product (free or otherwise), would my only option be creating my own ontology editor? Even in that case, I would need to know what practitioners need.

Btw - Protege is at the tail end of the timeline you suggest (released close to 20 years ago). But even if it was a novel tool, wouldn't it be useful to look at ways for improving it?

@william-vw
Copy link

When I wrote this, I did not have an ontology editor in mind. I wanted a general RDF editor which would have tab completes for predicates based on prefixes and things that my collaborators and I needed to create RDF data.

Yes, sorry .. I seem to have hijacked your issue here ..

I have used Protege in the past and it is fine as far as I can tell for editing ontologies (Tbox) but it is not for editing data files (Abox).

You can create instances in Protege, using auto-complete for predicates, instances and types. For instance, checkout the google results for tutorials on that (most of them use an older version of Protege though.. newer ones have auto-complete support).

@cyocum
Copy link

cyocum commented Dec 19, 2018

When I wrote this, I did not have an ontology editor in mind. I wanted a general RDF editor which would have tab completes for predicates based on prefixes and things that my collaborators and I needed to create RDF data.

Yes, sorry .. I seem to have hijacked your issue here ..

No problem. I just wanted to keep this on track :)

I have used Protege in the past and it is fine as far as I can tell for editing ontologies (Tbox) but it is not for editing data files (Abox).

You can create instances in Protege, using auto-complete for predicates, instances and types. For instance, checkout the google results for tutorials on that (most of them use an older version of Protege though.. newer ones have auto-complete support).

I just opened the newest version of Protege and this is really not what I am looking for. I want to see the file format; I want to see the URLs in it; I want to edit the file as it exists on disk. I want something that looks like one of the IDEs that I listed above and use everyday. Maybe I am being too inflexible about methods but I just want to edit some files with some help from my computer.

@william-vw
Copy link

Fair enough :-) In that case, the proposal by @ktk seems to make the most sense - i.e., creating a DSL (N3, Turtle) using XText and leveraging their support for auto-completion - it would have the added benefit of looking like an IDE as well.

@jmrog
Copy link

jmrog commented Dec 31, 2018

Hi, everyone. I got pointed to this thread by a comment over on the Stardog community forum. At Stardog, we've been using the Language Server Protocol to integrate language intelligence features (autcompletion, diagnostics, hover help, etc.) for SPARQL and Turtle into our own editor, Stardog Studio, for a while now. We've also just recently decided to open source the language servers as editor-agnostic libraries that can be used to get language intelligence in any editor that supports the LSP. You can find the most relevant ones (for this thread, anyway) here:

Turtle language server
SPARQL language server

Feel free to check them out, try them in editors of your choice, and submit feedback or PRs!

In case you're wondering, you can see a rubric showing currently supported features here. Basically, the SPARQL one supports autocomplete for keywords, hover help, and diagnostics (error reporting), and the Turtle one supports hover help and diagnostics (inside of Stardog Studio, the SPARQL one also does some special stuff like autocomplete predicates using the data in your database, etc.). These servers are still works in progress and under active development. FWIW, each of them relies on a parser that passes all of the W3C test suites we've thrown at it so far.

Once we re-locate our credentials for the VSCode marketplace 😆, we'll also be publishing VSCode extensions that use these servers, so you'll have an open source example of integrating them with a widely-used editor. (There are also some instructions in our repo about integrating the servers with Neovim as a client, and they should work, but we haven't actually tested them yet.)

Would love to hear whether anyone here ends up trying them out!

EDIT: Apparently the README isn't showing up correctly on npm (we'll fix that), but the general README for the servers is definitely available in our repo.

@ktk
Copy link

ktk commented Dec 31, 2018

@jmrog great work, thanks Jason! That will be useful indeed, especially for the cases where a full-fledged DSL is overkill.

@VladimirAlexiev
Copy link

VladimirAlexiev commented Jan 30, 2019

I mean something like

Thanks!

@ktk
Copy link

ktk commented Jan 30, 2019

@VladimirAlexiev it's not ready for prime time yet but I planned doing a short screencast about what we have so far. Will try doing that next week

@ktk
Copy link

ktk commented Jan 30, 2019

@VladimirAlexiev within Eclipse it is close to what the animated screenshot is doing

@irenetq
Copy link

irenetq commented Mar 31, 2019

@cyocum, source code editing in TopBraid Composer offers a selection of resources based on the prefix and whatever part of the local name has been typed so far. This is also available for SPARQL queries and for the form fields.

@william-vw, when you say Protege is the only available ontology editor, is it because you do not know about TopBraid Composer or is it because you know about it and don't consider it to be an ontology editor?

Btw, with respect to web-based, collaborative ontology development, TopBraid EDG offers pretty much the same capabilities as Composer.

@william-vw
Copy link

@irenetq I did not know about it, thanks for pointing this out! I will certainly try it out.

@cyocum
Copy link

cyocum commented Mar 31, 2019

@irenetq

@cyocum, source code editing in TopBraid Composer offers a selection of resources based on the prefix and whatever part of the local name has been typed so far. This is also available for SPARQL queries and for the form fields.

I just tried it and it does not support TrIG and is thus not terribly useful to me. Additionally, it seems to be another Ontology editor which I do not need. I need something that allows a human being to sit down and write TrIG or Turtle or JSON-LD with ontology aware autocomplete. Also, looking at the Source Code section of the Turtle file I just tried to create, there is no syntax highlighting. I am sorry but this does not fit my use case.

@irenetq
Copy link

irenetq commented Mar 31, 2019

@cyocum, are are right, it is a true, full featured ontology editor. Source code editing is just one of the features. It autocompletes or gives a selection of possible matches on Control/Space (on the Mac, on Windows may be Ctrl/Space, but I am not certain).
There is syntax highlighting for code snippets in SPARQL Web Pages and for SPARQL queries.

Until your post, we have not heard from any users requiring to have syntax highlighting for RDF. In most cases Turtle syntax is quite simple unless you are creating complex statements involving OWL restrictions or SHACL shapes. These can be quite involved and, in our experience, typically better done using forms with guided wizards, possibly, visual editing and, in case of OWL, Manchester Syntax which is also supported with syntax highlighting.

We are planning to support syntax highlighted entry of SHACL Shapes in the next release (in addition to forms, etc.).

The idea of having ontology aware Turtle editing for instances is interesting. I am not sure how many users would want it though. In most cases, they are looking for forms or grids - as described in #53 .

With respect to TriG for multiple graphs, our practice today is to manage each graph individually, support the way to create an assembly of graphs using owl:imports and then, if desired, export a TriG dataset. I do not foresee this changing unless we hear of several users wanting something different.

We also support syntax highlighting for GraphQL with capabilities that allow import of JSON - see this page for details.

@VladimirAlexiev
Copy link

There are some other data, ontology and thesaurus editors that try to compete with TopQuadrant:

  • EU ISA, OPOCE & UniRoma1: VocBench, open source
  • SWC: PoolParty
  • Synaptica: Graphite

@irenetq
Copy link

irenetq commented Apr 3, 2019

Is this ticket about ontology/rules editing or about RDF data editing? Asking because there is also #53.

@VladimirAlexiev, I would not call any of these general data or ontology editors. They are primarily/only thesaurus/SKOS editors. Having said this, it is good that there are more choices at least for thesauri.

@william-vw
Copy link

@irenetq

@VladimirAlexiev, I would not call any of these general data or ontology editors. They are primarily/only thesaurus/SKOS editors. Having said this, it is good that there are more choices at least for thesauri.

I'd say that at least VocBench qualifies as a general ontology editor - it has many of the same features as Protege.

@irenetq
Copy link

irenetq commented Apr 3, 2019

@william-vw , it must have moved on since I last checked. Hard to keep track of the details of the evolving offerings. Does the fact that you now know of at least two alternatives to Protege, address your original concern?

@william-vw
Copy link

@irenetq It does to an extent, thanks.

My preference would still go towards systems that integrate with fully fledged OWL2 DL reasoners (AFAICT the TopBraid system supports OWL2 RL only?), since that is my personal interest, but it's very encouraging to see that there's more than one ontology editor!

@nvbach91
Copy link

nvbach91 commented May 7, 2020

'Recently both Atom and Visual Studio Code have both come to the
mainstream. While there are many plugins that will do automatic code
completion for you in Javascript, Java, etc. There is none out there
that will do that for you in Turtle."
https://lists.w3.org/Archives/Public/semantic-web/2018Dec/0088.html

https://github.com/thomsonreuters/AtomOntologyCompleter this one looks promising

@angelo-v
Copy link

angelo-v commented May 8, 2020

For Intellij IDEA there is LNKD.​tech Editor. I like it very much so far and it is making progress. 👍

@KMax
Copy link

KMax commented Jun 15, 2020

There is another plugin for Jetbrains IDEs, see RDF and SPARQL. It supports completion suggestions both for Turtle and SPARQL, and of course other features. There is no need to buy any of Jetbrains IDE to use it.

Let me know if you have any specific needs or use cases, I'm the author of the plugin.

@draggett
Copy link
Member

If you're willing to try something different, take a look at the W3C Cognitive AI CG which is working on a simple format for an amalgam of RDF and property graphs. Chunks are typed n-ary terms whose values name other chunks. They also support booleans, numbers, ISO8601 dates, string literals, lists as arrays, and condition-action rules. A formal spec is in preparation along with an expanding series of demos.

@lonniev
Copy link

lonniev commented Aug 23, 2020

Cognitum (info/download) in 2015 had a promising editor. It doesn’t seem to have evolved since then and being a Windows app always kept it outside my easy reach.

I agree with @cyocum that a ontology-aware, reasoning, code-completer for Turtle in VSCode would be very handy. Also, something like the Open Refine RDF Extension for tabular data in one of VSCode’s table editor plugins would be spiffy.

@nvbach91’s URL for AtomOntologyCompleter looks directionally correct - but it is for Atom and I’ve switched to VsCode and adding ontologies isn’t just the addition of a prefix to a resolvable RDF or OWL file.

Regarding the two Protégés, it would be great if everything good in desktop Protege was merged into Web Protege and a single web-friendly, collaborative unified Protégé emerged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Category: tools For RDF tools primarily-tools Tool makers should address this
Projects
None yet
Development

No branches or pull requests