The Knowledge Graph Conference Icon
The Knowledge Graph Conference
  • 🏠Home
  • 📅Events
  • 👤Members
  • 🔵Announcements
  • 🔵Ask
  • 🔵Ask The Ontologists
  • 🔵Events
  • 🔵Jobs
  • 🔵Promotions
  • 🔵Share
Powered by Tightknit
Promotions

New Front-End Development Library for RDF Released!

Avatar of Borislav Iordanov
Borislav Iordanov
February 12, 2024

Dear KGC Community, Announcing the release of a new front-end application development library for RDF. Most of us have heard time and again how programmer unfriendly RDF is. Having bitten the bullet several times and having built some fairly large applications on top of RDF, I want the next one to be more fun and easier to write. Link: https://github.com/kobrixinc/fdr. Would love to hear feedback, or even better, get some collaboration if you like where this is going. While not a 1.0 yet, it is being actively used in another project, it is solid and worth your attention if you are contemplating writing browser based apps with a semantic back-end. Kindly, Boris

🎉3

32 comments

· Sorted by Oldest
    • Avatar of Raphael Troncy
      Raphael Troncy
      ·

      Did you check out SPARQL Transformer that does make RDF very developper friendly? There are large RDF-based applications that makes use of it efficiently.

    • Avatar of Thomas T.
      Thomas T.
      ·

      What are the advantages of building applications on top of RDF rather than API endpoints? I've built more than one on top of RDF and found it difficult to keep up with ontology changes. And then it doesn't scale when you have a second webapp doing similar things. Since then, I've sort of convinced myself that no one builds UI apps on top of relational databases (no one says "here's my sql endpoint and my table structure") and caved with API based dev. Unfortunately, the RDF space is behind LPG when it comes to OGM libraries though... I've seen some cool stuff with building widgets based on SHACL, there might be a way for you to incorporate that into your framework ^_^. Pros/cons that you've run across with your work with building UI directly on top of SPARQL endpoints?

    • Avatar of Renato I.
      Renato I.
      ·

      Expose GraphQL to your developers ….

    • Avatar of Thomas T.
      Thomas T.
      ·

      +1 for GraphQL. The introspection tools are great

    • Avatar of Borislav Iordanov
      Borislav Iordanov
      ·

      Raphael Troncy I wasn't familiar with SPARQL Transformer, thanks for pointing it out. I have written similar JSON-LD template/pattern query systems (sort of inspired by Freebase's MQL if you have seen it), including one capable of federating b/w RDBMs and triplestores, and I do appreciate the value of this approach. FDR is a programming API/framework that comes in after you've solved the problem of how to query your data. What does a mutable JavaScript object, mapped to some RDF subgraph, look like and how does one manage changes to the graph, including things like front-end reactivity.

    • Avatar of Borislav Iordanov
      Borislav Iordanov
      ·

      Renato I. Thomas T. Sure, but again that's also just a means querying, an interface to a triplestore. I am more interested in a domain model expressible in the programming language used to develop the app, how that domain model gets mapped to the underlying RDF substratum, how mutations are handled, both in the front-end, but also coming from the backend in the form of push notifications for example. I want a familiar looking JavaScript/TypeScript object that is somehow mapped to an RDF representation (I don't care how exactly) and I don't want to spend 80% of my engineering effort thinking how to propagate changes to my model between its different realizations.

    • Avatar of Borislav Iordanov
      Borislav Iordanov
      ·

      Thomas T., I think you are raising exactly the right questions. Yes, LPGs appear (but I think only superficially so) ahead of RDF when it comes to programmatic interfaces and OGM, but that is a big part of what we are trying to do with FDR - fill that void. But also, backend APIs are still a perfectly valid and often desirable architectural choice. FDR + SPARQL endpoint is not the only scenario. In fact, the project using FDR I alluded to above does NOT have a SPARQL endpoint, but an API at the back. However, I just want to make it clear that we don't have a complete OGM yet. Some ideas, but not ready to commit to an approach. You are right that there are some interesting attempts using SHACL. I have never build serious apps directly over SPARQL endpoints, only quick POCs. Mid-tier APIs are ok, they have a role to play, I just don't think they have to fully "own" the business model so to speak. I also don't think what one does to map RDF<->runtime object model has to follow the traditional ORM approach. As you realized, ontologies change and that's one of the advantages over RDBMs (the no schema, or flexible schema aspect), so we have to content with that. In general, ORMs allow a programmer to easily move from a relational representation (and mental model) to an object representation (and mental model). We need to find a way to do something analogous for RDF: move between the two representations & mental models. But the analogy stops there, the solution may not look exactly the same as an ORM.

    • Avatar of Raphael Troncy
      Raphael Troncy
      ·

      Thomas T. SPARQL Transformer DOES expose a RESTful API on top of any RDF graph. Hence, you do not bother anymore with SPARQL. You only do GET / POST API calls in your app. SPARQL Transformer is enabling you to specify the enveloppe response that the developer wishes to have to avoid merging results, deduplicating, etc. It is integrated into grlc so that you can drop SPARQL Transformers template in a git repository and you get immediately for free a RESTful API deployed + Swagger documentation! See http://bit.ly/transformer-iswc19 for all features. More at https://github.com/D2KLab/sparql-transformer + playground at https://d2klab.github.io/sparql-transformer/

    • Avatar of Thomas T.
      Thomas T.
      ·

      Renato I. - do you have any suggestions for GraphQL over RDF? The following writeup is a bit old, and the open source options listed haven't been touched in years https://www.w3.org/Data/events/data-ws-2019/assets/position/Ruben%20Taelman.pdf

    • Avatar of Renato I.
      Renato I.
      ·

      Some graph vendors support GraphQL (as well as SPARQL) such as Ontotext and StarDog - some only have query capabilties (not mutations)

    • Avatar of Renato I.
      Renato I.
      ·

      And there are some open source options, for example: https://www.npmjs.com/package/graphql-to-sparql

    • Avatar of Vladimir A.
      Vladimir A.
      ·

      Renato I. but do you recognise how bad Cartesian explosions this causes?

    • Avatar of Rashif Rahman
      Rashif Rahman
      ·

      Excited to dig into this! Thomas T. I also agree with you on the LPG front when it comes to OGMs (e.g. Neo4j-GQL in JS), having experienced building not only KGs but KG-backed apps in both paradigms. Few people venture into apps with RDF but those who do have clearly seen the value. An ontology, while not necessarily OWL or RDF but is accessibly so, can do wonders for driving user interfaces. You might have seen this in action with ShaCL. Now with LLMs in the picture, there are many more interesting ways to exploit RDF in the front-end.

    • Avatar of Martynas J.
      Martynas J.
      ·

      Raphael Troncy isn't RESTful API on top of RDF just called Linked Data? You can deploy such read-write on top of any SPARQL endpoint using Processor which will translate HTTP requests to SPARQL queries/updates. https://github.com/AtomGraph/Processor

    • Avatar of Martynas J.
      Martynas J.
      ·

      Thomas T. Borislav Iordanov OGM (assuming object-graph mapper) is the last thing you need when building applications on top of RDF. It requires to keep the object model in sync and basically cancels all the flexibility of the RDF data model, and it suffers from impedence mismatch just like ORMs do. In fact the leanest architecture is getting rid of the object-oriented model altogether and working directly with triples and SPARQL.

    ❤️1
    👀
    1