VirtTipsAndTricksCustomControlLabelsURICustom Controlling Virtuoso Labels for URI functionalityCustom Controlling Virtuoso Labels for URI functionality What is this? A component of Virtuoso's DBMS hosted faceted browser engine for Linked Data that enhances UI by automagically relegating URIs to the @href attributes of an HTML anchor while using label property values for actual anchor text.Why is this important? The fundamental UI/UX goal of Linked Data oriented client solutions should always be to make URIs invisible without compromising their inherent power re. Web experience e.g., the ability to drill-down from an position on the WWW graph using click (de-reference) based follow-your-nose patterns.URIs lie at the very core of that makes the Web and its Linked Data dimension tick. Unfortunately, they are also distracting to most end-users thereby compromising UI aesthetics. How do I use this functionality? First, lets understand the fundamental challenge. There are a number of annotation oriented attributes (or predicates) used in relations across databases, data spaces, and stores the exposed access to Linked Data. Unfortunately, there isn't a universally adopted attribute/predicate for 'labels', since everyone doesn't uniformly use rdfs:label when constructing Linked Data.Virtuoso solves the problem at hand by enabling you to populate a named graph with rdfs:subPropertyOf and owl:equivalentProperty relations (triples) that map disparate annotation properties to Virtuoso's in-built virtrdf:label annotation property. Once in place, the aforementioned named graph is then used as the basis for an inference rule that's optionally available for use via SPARQL and/or the Faceted Browser. Example This is example is focuses on the in-built 'facets' named graph that is used by faceted browser engine. Prerequisites Make sure the following packages are installed: Cartridges Virtuoso Faceted Browser Basic Steps Load for ex. by accessing: http://localhost:8890/about/html/
View http://cname/describe/?url=, so for ex.: http://localhost:8890/describe/?url= As result the "About" value will be shown as URI:
Next use SPARQL 1.1 Update Statement to populate the 'facets' named graph: SPARQL INSERT INTO GRAPH <facets> { <> rdfs:subPropertyOf virtrdf:label . <> rdfs:subPropertyOf virtrdf:label . <> rdfs:subPropertyOf virtrdf:label . <> rdfs:subPropertyOf virtrdf:label . <> rdfs:subPropertyOf virtrdf:label . } ; Query result: callret-0 ANY Insert into <facets>, 5 (or less) triples -- done No. of rows in result: 1 Use the named graph above as the basis for an inference rule or simply issue this command whenever you've added new relations to the 'facets' named graph: rdfs_rule_set ('facets', 'facets'); Note: In situations where you have alternative named graphs (e.g. 'virtrdf-label') which the relations you seek in an alternative named graph, you can bring those to bear by issuing the following command: rdfs_rule_set('facets','virtrdf-label'); View again http://cname/describe/?url=, so for ex.: http://localhost:8890/describe/?url= As result the "About" value will be shown as label: TimBL
Related Facets Web Service: Virtuoso Facets Web Service Linked Data: Faceted Views over Large-Scale Linked Data Facet Browser Installation and configuration: Virtuoso Facet Browser Installation and configuration Facet APIs: Virtuoso APIs for FCT REST services UNKNOWN tag: API Example Pivot Viewer and CXML: Facet Pivot Bridge - A bridge to PivotViewer from Virtuoso's Faceted query service for RDF Auto-Detection of Facet Type Tutorials: Faceted Browsing Sample using LOD Cloud Cache data space SOAP Facets Example Querying The Facet Browser Web Service endpoint Virtuoso Facet Browser Featured Queries Visualizing Your Data With PivotViewer Using The Facet Browser Facets Web Service: Examples for customizing different types Facets Web Service: Choice of Labels Example Downloads: Latest Virtuoso Virtuoso Facet Browser VAD package