Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Apr 09 10:20

    ericprud on shapes-as-collection

    ~ prototype shapes as a list (compare)

  • Apr 09 10:19

    ericprud on master

    + pared-down @context (compare)

  • Apr 06 22:47
    ericprud commented #97
  • Apr 06 14:19

    ericprud on master

    + ShexMan.jsonld (compare)

  • Mar 24 19:53
    goodb commented #115
  • Mar 24 17:40
    andrawaag commented #115
  • Mar 24 17:39
    andrawaag commented #115
  • Mar 24 13:53
    andrawaag opened #115
  • Mar 22 19:32
    metasj commented #97
  • Mar 22 19:31
    metasj commented #97
  • Mar 16 18:55

    emulatingkat on master

    Update 20210317-agenda.md (compare)

  • Mar 02 10:16
    ktk opened #39
  • Mar 02 10:08
    ktk opened #38
  • Mar 01 00:40

    ericprud on gh-pages

    - ` type` on `<script src="jque… (compare)

  • Mar 01 00:36
    ericprud commented #21
  • Mar 01 00:33

    ericprud on master

    Minor ReSpec updates. Merge pull request #22 from she… (compare)

  • Mar 01 00:33
    ericprud closed #22
  • Feb 28 00:05
    gkellogg review_requested #22
  • Feb 28 00:05
    gkellogg opened #22
  • Feb 28 00:05

    gkellogg on respec-update

    Minor ReSpec updates. (compare)

Eric Prud'hommeaux
@ericprud
@nishad , @gkellogg is the maintainer of the rub ShEx gem
danbri
@danbri:matrix.org
[m]
So if we had the triples for some shape definitions, how would we easily create ShexJ files with the right syntax structure? (Reposting from chat with eric)
trying to avoid having custom code that cares about syntax, or volatile dependencies
(And prefer Python...)
Sorry to be picky! But they could be really interesting shape definitions...
Eric Prud'hommeaux
@ericprud
@gkellogg , have you taken a stab at framing to ShExJ with the latest framing impls?
@hsolbrig , have you got a ShExR recognizer? I think danbri's crew is living in python-land
danbri
@danbri:matrix.org
[m]
Yup, crew is Google
Eric Prud'hommeaux
@ericprud
don't they sell ads or something like that?
danbri
@danbri:matrix.org
[m]
I really should get around to watching Mad Men
If there’s straightforward code in another language maybe we could port it to py?
Eric Prud'hommeaux
@ericprud
i have a not-so-straighforward way to do it in my code.
Sameroom
@sameroom-bot
[Harold Solbrig] I don't have a ShExR recognizer, but could build one pretty quickly if you need it
[Harold Solbrig] Basically we need to add framing information to shex.context.jsonld
Eric Prud'hommeaux
@ericprud
i validate it against ShExR.shex and use the proof to construct the schema object which i can save as JSON
go with harold's approach
Sameroom
@sameroom-bot
[Harold Solbrig] The way we go from ShEx(J) to ShExR is via json-ld anyway
[Harold Solbrig] Harold Solbrig what is the deal with the apostrophe 'd'?
[Eric Prud'hommeaux] i corrected it in gitter but sameroom didn't transcribe it here
danbri
@danbri:matrix.org
[m]
So to go from shex triples to shexJ, is that even possible in python today?
Sameroom
@sameroom-bot
[Jose Emilio Labra Gayo] One possibility is to invoke a web service
[Jose Emilio Labra Gayo] rdfshape does that already but you would need to invoke it as a web service
1 reply
Eric Prud'hommeaux
@ericprud
I think Ima write a ShEx-driven RDF parser generator that will compile the equivalent of a recursive descent parser that operates against some API (RDFJS, in my case, but can be made to work over python's RDFLib with clever tools like sed
Sameroom
@sameroom-bot
[Harold Solbrig] I'm sorry, can you restate that in English?
[Harold Solbrig] Harold Solbrig wonders what language IS he speaking?
[Harold Solbrig] FWIW - if you were to wrap rdflib triple (which is what we do in in some of the PyShEx implementations, you could simply record the queries that went through. The problem, however, is that you wouldn't follow all paths, eh?
Eric Prud'hommeaux
@ericprud
if i walk through https://github.com/shexSpec/shexTest/blob/master/doc/ShExR.shex , i can build something that populates a data structure with the values from that schema. that data structure, when expressed in JSON, should basically be ShExJ
1 reply
and if i'm wrong, i'd like to know that
danbri
@danbri:matrix.org
[m]
Or tell us ShexR (with some tweaks to use collections) is a legit alternative to shexJ?
Eric Prud'hommeaux
@ericprud
yeah, it's very well defined by the @context
but all of the tooling uses ShExJ because it's basically the compiled form of ShEx (i.e. an AST)
which means those tools will ultimately need to recognize said RDF and parse it to be ShExJ
(at least, all of the current tools that i know of use ShExJ)
danbri
@danbri:matrix.org
[m]
If we can get stuff out of Google in some stable shex variant, that would be a great milestone
Currently it is easy to dump shacl triples, and a bit “it’s complicated!” wrt shex
Eric Prud'hommeaux
@ericprud
right. ok, let's fix this
i assume that by dump, you mean dump in Turtle
(vs. json-ld)
danbri
@danbri:matrix.org
[m]
could be
they both have their issues!
but if it is in github a Github Action could run and maintain other flavours maybe
Eric Prud'hommeaux
@ericprud
'cause the JSON-LD is an RDF representation; it's just that it takes a JSON-LD processesor, and they're heavier-weight and less common than Turtle parsers
my pref, if someone's gone to the effort of creating a JSON-LD representation, is usually LD 'cause it offers the mythic dual access
Eric Prud'hommeaux
@ericprud

re the change to the (ordered) collection of shape expressions in a schema, that's a one-line change to https://www.w3.org/ns/shex.jsonld:

    "shapes": {
      "@id": "shex:shapes",
      "@type": "@id"
    }

needs "@container": "@list", but that also needs some quick discussion in the CG

Eric Prud'hommeaux
@ericprud
btw, that change takes the RDF output from https://tinyurl.com/26tfanhr to https://tinyurl.com/vdvu84mv
prettier in Turtle:
PREFIX shex: <http://www.w3.org/ns/shex#>

[] a shex:Schema ;
  shex:shapes ( <http://a.example/S1> <http://a.example/S2> ) .

<http://a.example/S1> a shex:Shape ;
  shex:expression [
    a shex:TripleConstraint ;
    shex:predicate <http://a.example/p1>
  ] .

<http://a.example/S2> a shex:Shape ;
  shex:expression [
    a shex:TripleConstraint ;
    shex:predicate <http://a.example/p2>
  ] .
danbri
@danbri:matrix.org
[m]
You think we should publish turtle then?
Gregg Kellogg
@gkellogg
@ericprud Haven't done anything with framing ShEx recently. Main thing would be @included support and id/type maps that might be useful. You can play around in json-ld.org/playground and send me a link of what you're working with.