501
questions
1
vote
1
answer
44
views
OWL2 Ontology creates a "ghost" RDFS ontology due to missing `#`
Let's query the code of OWL2 Ontology.
$ http --follow get http://www.w3.org/2002/07/owl# | grep -B30 'rdf-schema>'
⇒
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xml: <...
3
votes
2
answers
40
views
Reasoning doesn't recognize subClassOf
in stardog studio, I have created a basic database. and added the following rdf data.
When I query this database with a reasoning "on", I don't find expected results.
I expect Alice, Charlie ...
2
votes
1
answer
40
views
SPARQL query returns 0 results when querying specific value in array
I am new to RDF and SPARQL, so i want to list all the Properties that https://schema.org/ListItem can have for example. This is the turtle file for https://schema.org/version/latest/schemaorg-current-...
0
votes
0
answers
18
views
Configuring Protege Default Relationships
I have a very small ontology in Protege containing just a few classes. Selecting a class in the class hierarchy pane shows several properties, including subClassOf and disjoinWith (see screenshot). ...
0
votes
1
answer
47
views
TypeError: RepositoryClientConfig is not a constructor
I am using node.js version 21.7.1 and graphdb version 10.0.6 to query the 'movies' repository that is in the interactive guide, I am using that as a test. My question is can I getting an error that ...
1
vote
2
answers
165
views
RDF: when a property is used the thing in the object position is a literal of datatype X
In quite a few ontologies we have triples like this:
gist:containedText
a owl:DatatypeProperty ;
rdfs:range xsd:string ;
What they intend to express is that if you use that property (gist:...
2
votes
0
answers
53
views
How to select only direct subClassOf element in a GraphDB custom ruleset?
In a GraphDB custom ruleset, I need to access only the explicitly declared superclass of an element, but I can't find any predicate (like sesame:directSubClassOf), nor use the implicit/explicit ...
1
vote
1
answer
35
views
How to structure an OWL property that be "Nobody"?
I am attempting to create an OWL ontology that includes a claimedBy property that could be a person, organization, or similar "agent" (foaf:Agent essentially), or could be unowned (owl:Thing ...
1
vote
1
answer
41
views
Jena Riot infers invalid RDF (with literals as subjects)
I'm feeding RDF inferred by the Jena riot CLI tool into the shacl cli tool.
My schema definition contains something like this:
lob:account_number
rdfs:domain lob:Account;
rdfs:range xsd:string ...
2
votes
0
answers
65
views
changing cism: Stereotype rdf:resource when exporting RDFS File
I'm using schema composer Tool of EA with which I generate RDFS-Augmented files?
The person that uses these Files needs following:
cims:stereotype rdf:resource="http://iec.ch/TC57/NonStandard/UML#...
3
votes
1
answer
545
views
When to use rdf:Type vs rdfs:subClassOf
I am fairly familiar with ontologies and OWL and use them all the time. But one idea has always eluded me and when I try to find a good answer there are always contradictions. That is, when to use rdf:...
0
votes
1
answer
164
views
Validating an JSON-LD JSON object against RDF
I have a JSON object that should be JSON-LD. I would like to programatically validate that is the case. The JSON-LD Spec has a @context and a @type that point a description document. In my particular ...
2
votes
2
answers
148
views
How to handle multiple graphs in Blazegraph?
I'm using a public graph that I download and load on Blazegraph.
I'm now familiar with SELECT and CONSTRUCT requests on this graph.
I don't know if that matters, but the graph includes multiple ...
0
votes
0
answers
35
views
What is the preferred approach to express pure SHACL shape inheritance
I have a quick question about the best way to express inheritance between pure SHACL shapes.
E.g.
:aShape a sh:nodeShape .
:bshape a sh:nodeShape .
Are the following 2 options equivalent, and which ...
1
vote
2
answers
88
views
RDF vs. RDF Model vs. RDF Data Model
I don't understand whether "RDF", "RDF Model", and "RDF Data Model" are describing different concepts or no, and if yes, what are the differences.
For instance, in this ...
1
vote
1
answer
76
views
How to correctly query the Pizza Ontology with SPARQL?
This request returns all pizzas with mushroom topping:
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX rdfs: <http://www.w3....
0
votes
0
answers
69
views
RDFS subClassOf: Can a class be a subclass of itself?
I want to create an ontology where a concept can be a subclass of another concept.
For example: a concept called "Planting" with sub-concepts "Propagation" and "Germination&...
0
votes
1
answer
38
views
Not able to get all subclasses from Protégé query
I'm trying to get all classes information with a query like this: tire that HasWidth some Width125. What I expect to have is the list of all classes that have or could have the indicated width.
That's ...
0
votes
0
answers
26
views
Why are rdfs and owl not working in this query?
This SPARQL query should print a list that has a first column stating the name of the disease the patient has, a second column stating the other factor for the death of the patient and finally a third ...
0
votes
0
answers
48
views
How to infer a property depending on a comparison between two (transitive) properties on two individuals?
I am modeling an ontology that shall be used to decide whether a person (a legal subject) is legally capable of accepting a contract. To do so, I model the contract itself, the jurisdiction it is ...
0
votes
1
answer
80
views
Unable to validate and serialize new inferred graph from pyshacl
I'm stuck with a problem and I need your help. I'm working on pyshacl validation, which is a Python library for validating RDF graphs against SHACL graphs. I have a shacl shape graph that has a SPARQL ...
1
vote
1
answer
167
views
How to update RDF graph by instantiating the variables existing in triples with values?
I have a knowledge base that looks as follows:
@prefix ex: <http://example.org/> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
ex:a a ex:C .
ex:C rdfs:subClassOf ex:D .
ex:D ...
0
votes
0
answers
60
views
How to describe a rdfs:range with multiple values
I have a class stk:vzg. Now i want to specify a property stk:hasLa, that has stk:vzg as the domain. I know i can do that as follows:
@prefix ...
stk:vzg rdf:type rdfs:Class .
stk:hasLa rdf:type rdf:...
1
vote
2
answers
52
views
DBPedia SPARQL query "NaturalPerson" brings back no data?
The following brings back a list of people - relating to a pages about Podcasts:
SELECT *
WHERE
{
?person rdf:type dbo:Person,foaf:Person,schema:Person;
rdfs:label ?name;
dbo:...
1
vote
1
answer
125
views
OWL: Create a class definition that has multiple object properties that need to be related?
I am trying to define a class in terms of the relationship between its object properties. I'm not sure if it's expressible in OWL/Protege, and wanted some opinions. Moreso, even if possible, I wonder ...
1
vote
0
answers
29
views
number of Instances of a custom class declared in a schema
I have an example of this data and its rdf schema:
and the schema
#Dimension - row
:GeographicalRegion
rdfs:subClassOf scovo:Dimension;
dc:title "Police force area, English ...
0
votes
0
answers
61
views
OWL beginner question: Difference between rdfs:range and Restriction with owl:allValuesFrom
as a beginner in OWL I find the difference of rdfs:range and Restrictions with owl:allValuesFrom a bit hard to grasp.
In "Semantic Web for the Working Ontologist" (2nd Edition) chapter 11, ...
0
votes
0
answers
83
views
Using a Property Chain with a reasoner is considered to be reasoning. Would it also be considered as reasoning if this is done via a SPARQL query?
We can define the followin property chain:
SubObjectPropertyOf(
ObjectPropertyChain( :hasParent :hasParent )
:hasGrandparent
)
And using a reasoner would add the hasGrandparent relation ...
6
votes
1
answer
505
views
What URI scheme should be used for a local concept in RDF?
Consider the case where you have some knowledge you want to name and you want to put it into a knowledge graph format like the resource description framework (RDF). However, you don't have an email, a ...
1
vote
1
answer
215
views
Reuse existing classes in an ontology
I design my own ontology and I reuse items from other ontologies. Is it good or bad practice to subclass an item from another ontology under an existing one? Or should I define my own subclass?
...
1
vote
1
answer
121
views
How to combine schema.org, RDFa and DBpedia in HTML?
I need to embed RDFa data into HTML using Schema.org and DBpedia.
Here is the HTML code (without DBpedia):
<div vocab="https://schema.org/" typeof="Organization">
<span ...
1
vote
1
answer
62
views
Are these RDFs the same thing?
I saved and generated these RDFs using the Jena API, and it came out as follows.
<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF
xmlns:rdf="http://www.w3.org/1999/02/...
3
votes
1
answer
238
views
Is rdfs:subClassOf really transitive?
I loaded this turtle file into two different OWL reasoners (HermiT and RDFox):
@prefix : <http://www.semanticweb.org/justin/ontologies/2022/10/untitled-ontology-16#> .
@prefix owl: <http://...
0
votes
0
answers
70
views
How to model Logical Expression using Protege OWL
I have structure like below
Now I have some expression which states which Part combination is a valid one
like these
Logical representation:
(Part1_3 and Part2_A and (Part3_0 or Part3_1))
or
(...
1
vote
1
answer
167
views
Access subclassOf/subclassOf level using ForwardChainingRDFSInferencer with SPARQL
I am running some SPARQL queries using the class ForwardChainingRDFSInferencer, which basic constructs an inferencer. For my examples I use the schema.org ontology.
My code looks like the following ...
0
votes
1
answer
118
views
How do linked open data datasets linked together?
I'm learning about RDF databases and the concept of "Linked Open Data (LOD)". According to what Wiki saids about LOD, many open-accessible datasets are published online and some of the ...
1
vote
1
answer
56
views
How does rdf refer to rdfs if rdf came earlier?
For example:
rdf:Property a rdfs:Class ;
rdfs:isDefinedBy <http://www.w3.org/1999/02/22-rdf-syntax-ns#> ;
rdfs:label "Property" ;
rdfs:comment "The class of RDF ...
1
vote
1
answer
44
views
counting the number of rdfs:label properties with NON-NULL values from DBpedia
I need to count the number of rdfs:label properties with NON-NULL values from DBpedia.
I already have the total number of rdfs:label properties (NULL and NON-NULL values) from DBpedia using this query:...
1
vote
0
answers
40
views
Retrieve the subjects that have at most two properties
I wanted to retrive subjects which have less than three properties. I tried with following query.
SELECT ?s
WHERE {
?s ?p ?o .
}
group by ?s
having (count(?p) < 3)
limit 10
But it's taking quite ...
0
votes
1
answer
102
views
SPARQL CONSTRUCT query specific hierarchy pattern
The construct query is supposed to reveal a specific hierarchy. Starting from my leaf object a component of a machine (going upwards) until my root object (company).
BUT, what it does is, if I start ...
0
votes
0
answers
40
views
query in Wikidata: how to retrieve the labels for instances
I'm trying to get info e.g. for Belgium for aerodromes or stations with having the label of all instances for each item (e.g. Brussels South Charleroi Airpor can be an airport, business, etc..)
I've ...
1
vote
1
answer
798
views
What exactly is the Prefix attribute on the HTML tag and why is it necessary/used?
So I came across BritishMuseum.org. Inspecting the HTML as you do I noticed a strange prefix attribute.
<html lang="en" prefix="content: http://purl.org/rss/1.0/modules/content/ dc: ...
0
votes
1
answer
72
views
How to define a ns uri modeltype for an own RDF Schema metamodel in qvto?
I've built an RDF schema Metamodel and want to define a modeltype for my RDF Schema.
I've these files : a metamodel uml (KB3Import.uml) and an other one in rdf schema (MyFirstProfile_CIMSdF_v6.rdf)
So ...
0
votes
1
answer
215
views
Retrieve only one label from set of individuals with multiple labels
Suppose I have the following set of individuals, where some of them have more than one rdfs:label:
Individual
Label
ind_01
"ind-001"
ind_02
"ind-002"
ind_02
"ind-2"
...
2
votes
0
answers
103
views
Verify rdf:Container(rdf:Seq) using shacl constraints
I am currently trying to build a constraint validation shape for an incoming object of the type rdf:Seq. The shacl shapes I have used, use the path to identify triple and then add additional ...
1
vote
2
answers
730
views
Parametrized SPARQL Queries with python RDFLib
I am trying to query a very simple database about Alloys with a parametrized SPARQL query using RDFLib:
x = "Inconel_625"
g = Graph()
g.parse ("Desktop/materials.ttl")
...
1
vote
1
answer
80
views
Get list of instances matching the intersection of all restriction values
I just started learning how to work with ontologies and make SPARQL queries. I am using a merged copy of these 2 ontologies - wine and food in GraphDB with OWL-Max ruleset.
I want to get a list of all ...
0
votes
0
answers
75
views
SPARQL dateTime subtraction with a particular format
Here we see that when I try to subtract 2 datetime with angular brackets it doesnt seem to work but if the angular is removed it works fine.
what I am currently doing is generating triplets via a ...
1
vote
1
answer
106
views
Graphdb seem to be missing rdfs:subClassOf inference
I am using the RDFS-Plus (Optimized) ruleset. According to this: https://docs.cambridgesemantics.com/anzograph/v2.2/userdoc/inferences.htm
If something is of type owl:Class it should be inferred it ...
1
vote
0
answers
137
views
Wikidata ontology to Produce a larger subgraph by extracting the subgraphs of some relevant books, birthplace, education institutions, etc
I want to load the wikidata ontology in stardog studio to produce a larger subgraph by extracting the subgraphs of some relevant books, birthplace, education institutions from the wikidata. I am not ...