Example code

2018-03-17 Thread David Moss
Nearly all the example code on the web for Jena is restatement of Javadoc.
This is better than nothing, but what seems to be missing is examples of how 
Jena is used in real-world applications.
I believe publishing practical examples would dramatically increase the use of 
Jena and semantic processing in general.

Without a pool of practical examples people using Jena are working in isolation.
There are so many ways of achieving results, but which are the ways people are 
actually using in real applications?

For example, when using data from a SPARQL endpoint, what is the accepted way 
to retrieve it, store it locally and make it available through user interface 
controls?
As far as I can tell there are no examples of how to do this anywhere.

ie How would you go about populating a dropdown list in a UI with data from a 
SPARQL endpoint?

Am I missing something (I hope so!)
If not, does anyone want to contribute some examples of using Jena in 
real-world applications?

If it turns out there are no such examples out there and no-one wants to 
contribute examples, I will write some myself. But they will be awful!
I’d much rather people with experience provided this much needed information. 
I’m happy to collate and publish.

DM









Re: Vocabularies for actions

2018-03-17 Thread David Moss


On 18/3/18, 2:20 am, "Laura Morales"  wrote:

>all the vocabularies that I know of (and that I can find) seem to 
> *describe* something, like a Person. Is there any vocabulary to *ask for* an 
> action? For instance in the context of a source code repository, is there > a 
> dictionary to describe an "action to be performed" by a machine such as 
> "create new  by " or "add  to " or "fork  
> to "?

My take is that these ontologies are application specific. The examples you 
gave of GIT have no relevance outside that specific domain. There is no doubt 
there is a vocabulary within the Git application that contains the terms you 
seek. Whether it has been translated into rdf is another matter.

The closest you can find, to my knowledge, is the API:
https://developer.github.com/v3/repos/contents/

DM
 




Re: Vocabularies for actions

2018-03-17 Thread Laura Morales
I wasn't thinking of github or its API; just a general-case example. Anyway 
using HTTP verbs makes sense, I think this answers my question.
Thank you.
 
 

Sent: Saturday, March 17, 2018 at 7:44 PM
From: "Jean-Marc Vanel" 
To: "Jena users" 
Subject: Re: Vocabularies for actions
Laura, your use case is not clear enough .

Anyway, *ask for* an action on github to "create new  by " is
done by POSTing the right JSON on the github API URL .
And I don't see much difference between :

- asking for* an action on github to "create a new issue" , and
- simply, "create a new issue" on github

In both case the data about the issueis the same .

As a side note, AFAIK , on github the REST API is not in RDF. But if ones
writes a suitable JSON-LD @context , it would be as if the github REST API
is in RDF .




2018-03-17 17:20 GMT+01:00 Laura Morales :

> Hi,
>
> all the vocabularies that I know of (and that I can find) seem to
> *describe* something, like a Person. Is there any vocabulary to *ask for*
> an action? For instance in the context of a source code repository, is
> there a dictionary to describe an "action to be performed" by a machine
> such as "create new  by " or "add  to " or
> "fork  to "?
>
> Thanks.
>



--
Jean-Marc Vanel
http://www.semantic-forms.cc:9111/display?displayuri=http://jmvanel.free.fr/jmv.rdf%23me#subject

Déductions SARL - Consulting, services, training,
Rule-based programming, Semantic Web
+33 (0)6 89 16 29 52
Twitter: @jmvanel , @jmvanel_fr ; chat: irc://irc.freenode.net#eulergui


Re: Vocabularies for actions

2018-03-17 Thread Laura Morales
Ah this makes perfect sense. Thank you.
 
 

Sent: Saturday, March 17, 2018 at 7:29 PM
From: "Martynas Jusevičius" 
To: jena-users-ml 
Subject: Re: Vocabularies for actions
There are no "actions" (verbs) on Linked Data really, only resources
(nouns). They have descriptions that you can retrieve/change using generic
"verbs": HTTP methods GET, POST, PUT, DELETE.

You can remodel your actions simply in terms of appending and updating
resource descriptions.


Re: Vocabularies for actions

2018-03-17 Thread Jean-Marc Vanel
Laura, your use case is not clear enough .

Anyway, *ask for* an action on github to "create new  by " is
done by POSTing the right JSON on the github API URL .
And I don't see much difference between :

   - asking for* an action on github to "create a new issue" , and
   - simply, "create a new issue" on github

In both case the data about the issueis the same .

As a side note, AFAIK , on github the REST API is not in RDF. But if ones
writes a suitable JSON-LD @context , it would be as if the github REST API
is in RDF .




2018-03-17 17:20 GMT+01:00 Laura Morales :

> Hi,
>
> all the vocabularies that I know of (and that I can find) seem to
> *describe* something, like a Person. Is there any vocabulary to *ask for*
> an action? For instance in the context of a source code repository, is
> there a dictionary to describe an "action to be performed" by a machine
> such as "create new  by " or "add  to " or
> "fork  to "?
>
> Thanks.
>



-- 
Jean-Marc Vanel
http://www.semantic-forms.cc:9111/display?displayuri=http://jmvanel.free.fr/jmv.rdf%23me#subject

Déductions SARL - Consulting, services, training,
Rule-based programming, Semantic Web
+33 (0)6 89 16 29 52
Twitter: @jmvanel , @jmvanel_fr ; chat: irc://irc.freenode.net#eulergui


Re: Vocabularies for actions

2018-03-17 Thread Martynas Jusevičius
There are no "actions" (verbs) on Linked Data really, only resources
(nouns). They have descriptions that you can retrieve/change using generic
"verbs": HTTP methods GET, POST, PUT, DELETE.

You can remodel your actions simply in terms of appending and updating
resource descriptions.

On Sat, Mar 17, 2018 at 5:20 PM, Laura Morales  wrote:

> Hi,
>
> all the vocabularies that I know of (and that I can find) seem to
> *describe* something, like a Person. Is there any vocabulary to *ask for*
> an action? For instance in the context of a source code repository, is
> there a dictionary to describe an "action to be performed" by a machine
> such as "create new  by " or "add  to " or
> "fork  to "?
>
> Thanks.
>


Re: Vocabularies for actions

2018-03-17 Thread Don Rolph
Have you looked at the application of object properties?

On Sat, Mar 17, 2018 at 12:20 PM, Laura Morales  wrote:

> Hi,
>
> all the vocabularies that I know of (and that I can find) seem to
> *describe* something, like a Person. Is there any vocabulary to *ask for*
> an action? For instance in the context of a source code repository, is
> there a dictionary to describe an "action to be performed" by a machine
> such as "create new  by " or "add  to " or
> "fork  to "?
>
> Thanks.
>



-- 

73,
AB1PH
Don Rolph


Vocabularies for actions

2018-03-17 Thread Laura Morales
Hi,

all the vocabularies that I know of (and that I can find) seem to *describe* 
something, like a Person. Is there any vocabulary to *ask for* an action? For 
instance in the context of a source code repository, is there a dictionary to 
describe an "action to be performed" by a machine such as "create new  
by " or "add  to " or "fork  to "?

Thanks.