Questions tagged [jena-rules]

Jena rules is Java-based framework for building Semantic Web applications. An environment for RDF, RDFS and OWL, SPARQL and includes a rule-based inference engine. Three kind of rules (according with their execution model): forward rules, backward rules and hybrid rules.

Jena Rules provides three mechanism of rule execution:

  1. Backward Chaining Rules - are identified by using <-. These rules are interpreted as queries and the rule head (the conclusion part) contains a single atom which cannot be a built-in. The body (the condition part) is a conjunction between one or more triple patterns and/or built-ins.

  2. Forward Chaining Rules - are identified by using ->. They are executed by a forward engine and both the head and body may contain of conjunction of atoms.

  3. Hybrid Rules - consists in using one or more backward chaining rules in the head of a forward chaining rule.

Official documentation.

80 questions
0
votes
1 answer

No data available in table, when I customize the rules of JENA FUSEKI?

No data available in table, when I customize the rules of JENA FUSEKI? movies.ttl is the rdf:type owl:Ontology. And rules.ttl is my custom rule. After deleting the @prefix at the top of rules.ttl, as follows, [ruleComedian: (?p :hasActedIn ?m)…
Francis QING
  • 63
  • 1
  • 4
0
votes
1 answer

As a newbie in rule-based reasoning,how can I have a basic knowledge of the Resoning component of Apache Jena?

just like how Jena works in reasoning?or some relevant papers in rule-based reasoning?Thank U very much.
TtC
  • 43
  • 4
0
votes
0 answers

How to use Jena's Union model with inference rules

I'm trying to keep a big model with reference data and in memory and attach other models with inference rules, and I need matching rules to fire when new triples are coming, lookup the reference data and all the new triples to end up in the second…
Utgarda
  • 686
  • 4
  • 23
0
votes
2 answers

Create a new object using the inference rules

I have a semantic network. Is it possible to use a jena framework to create a new object in the semantic web based on some rule. For example there is an object has a certain property, then you need to create a new object and make a connection…
luk-alex
  • 311
  • 1
  • 9
0
votes
1 answer

OWL subclass defined in turtle

I try to add a bit of ontology to a (public) RDF dataset (wordnet), specifically I need to differentiate between LexicalEntries for Verbs and Nouns, separated as two subclasses. Following examples on the web and in the OWL standard, I assumed that…
user855443
  • 2,596
  • 3
  • 25
  • 37
0
votes
1 answer

Updating values in ontology triples with Jena rules

I have a question. I have a Jena rule like this: [rule1: (?if rdf:type p:InferredConfiguration) (?if p:userName ?userEmail) (?subProfile rdf:type u:PersonSubProfile) (?subProfile u:hasUsername ?email) equal(?userEmail, ?email) (?subProfile…
A.Sim
  • 91
  • 1
  • 10
0
votes
1 answer

SPARQL: Figure out high data property values

I have a quiz game in which students have to solve questions from three categories like Chemistry, English, Physics. Students will score points in these categories like student1 has 50 in Chemistry, 70 in English and 65 in Physics. I can figure out…
s.shah
  • 21
  • 6
0
votes
1 answer

Jena won't connect to custom online file

I tried to connect Jena to my custom file which I stored on a public directory on Dropbox with the following link https://www.dropbox.com/s/d3gfidqqfwvo4e9/foaf.ttl?dl=1. I've intentionally changed the link to dl=1 instead of dl=0 so the link would…
Ivan Janev
  • 33
  • 6
0
votes
0 answers

Is it possible to perform i/o from within JENA rules?

I'm interested in using Jena to build a fault diagnostic, ontology-based expert system. Is it possible to perform i/o from within forward- or backward-chaining rules? For example to prompt the user for further facts? Or to access a database?
0
votes
1 answer

Jena SPARQL API using inference rules file

I am working with Jena SPARQL API, and I want to execute queries on my RDF files after applying inference rules. I created a .rul file that contains all my rules; now I want to run those rules and execute my queries. When I used OWL, I proceeded…
user3510821
  • 113
  • 1
  • 5
  • 15
0
votes
1 answer

SWRL - using knowledge from classes

I want to use knowledge, which is modelled between classes. E.g. I have modelled a car and a bus have 4 wheels, a bike 2 wheels. Now, I want to express that bike can tip (if you don't keep them in balance - incompetent driver). If I add an instance…
2Application
  • 165
  • 10
0
votes
2 answers

Reusing inferred statements in InfModel to existing model in Jena

I have a Jena Model filled with statements and use a GenericRuleReasoner with custom rule strings as follow (Example directly taken from Jena tutorial page) String rules = "[rule1: (?a eg:p ?b) (?b eg:p ?c) -> (?a eg:p ?c)]"; Reasoner reasoner = new…
wns349
  • 1,266
  • 1
  • 10
  • 20
0
votes
2 answers

Jena rule example

I have this RDF description :
Fatma Fatma
  • 63
  • 1
  • 6
0
votes
1 answer

How to write Jena rule to query class and get individuals for a property

How to extract all actuators that are switched off when there are no users at home. I tried to write Jena rule but am unable to get proper output. I have added desired result that I want. Need help with writing rule. [rule1: noValue(:users…
user3747396
  • 141
  • 12
0
votes
1 answer

From a math expression to a Jena rule

Let A = {x1,x2,…,xn}. We want to calculate the difference between xi and xj, where xj is min{x ∈ A : x > xi }. It is possible to translate this kind of expression into a Jena rule?
paolo789
  • 3
  • 4