{"id":2770,"date":"2021-09-02T10:12:45","date_gmt":"2021-09-02T15:12:45","guid":{"rendered":"http:\/\/inova8.com\/bg_inova8.com\/?p=2770"},"modified":"2021-09-16T06:16:47","modified_gmt":"2021-09-16T11:16:47","slug":"pathpatternql-intelligently-finding-knowledge-as-a-path-through-a-maze-of-facts","status":"publish","type":"post","link":"https:\/\/inova8.com\/bg_inova8.com\/pathpatternql-intelligently-finding-knowledge-as-a-path-through-a-maze-of-facts\/","title":{"rendered":"PathQL:  Intelligently finding knowledge as a path through a maze of facts"},"content":{"rendered":"<div class=\"boldgrid-section\">\n<div class=\"container\">\n<p class=\"\">PathQL simplifies finding paths through the maze of facts within a <a href=\"https:\/\/inova8.com\/bg_inova8.com\/see-quorum360-provide-answers-to-users-analysis-searching-visualizing-or-other-questions-of-their-own-data\/\">KnowledgeGraph<\/a>. Used within <a href=\"https:\/\/inova8.com\/bg_inova8.com\/intelligent-graph-knowledge-graph-embedded-analysis\/\">IntelligentGraph<\/a> scripts it allows data analysis to be embedded within the graph, rather than requiring graph data to be exported to an analysis engine. Used with <a href=\"https:\/\/inova8.com\/bg_inova8.com\/intelligentgraph-getting-started\/\">IntelligentGraph Jupyter Notebooks<\/a> it provides powerful data analytics<\/p>\n<p class=\"\"><span style=\"font-weight: 400;\">I would suggest that Google does not have its own intelligence. If I search for, say, \u2018Arnold Schwarzenegger and Harvard\u2019, Google will only suggest documents that contain BOTH Arnold Schwarzenegger and Harvard. I might be lucky that someone has digested these facts and produced a single web page with the knowledge I want. I might, however, just as easily find a page of fake knowledge relating Arnold to Harvard.<\/span><\/p>\n<p class=\"\"><span style=\"font-weight: 400;\">It is undoubtedly true that Google can provide individual facts such as:<\/span><\/p>\n<ol class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Arnold married to Shriver<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Shriver daughter Joseph<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Joseph alma mater Harvard<\/span><\/li>\n<\/ol>\n<p class=\"\"><span style=\"font-weight: 400;\">However, <\/span><b>intelligence<\/b><span style=\"font-weight: 400;\"> is the ability to connect individual <\/span><b>facts<\/b><span style=\"font-weight: 400;\"> into a <\/span><b>knowledge<\/b> path<span style=\"font-weight: 400;\">.<\/span><\/p>\n<ul class=\"\">\n<li><span style=\"font-weight: 400;\"><strong>KnowledgeGraph<\/strong> models can provide the facts to answer these questions. <\/span><\/li>\n<li><span style=\"font-weight: 400;\"><strong>PathQL<\/strong> provides an easy way to discover knowledge by describing paths and connections through these facts. <\/span><\/li>\n<li><span style=\"font-weight: 400;\"><strong>IntelligentGraph<\/strong> embeds that intelligence into any <strong>KnowledgeGraph<\/strong> as scripts.&nbsp;<\/span><\/li>\n<\/ul>\n<p><span class=\"gdm-drivefile-embed\"><img src=\"https:\/\/drive-thirdparty.googleusercontent.com\/16\/type\/application\/pdf\" width=\"16\" height=\"16\" \/> <a href=\"https:\/\/drive.google.com\/file\/d\/1b9aIJz01LXz68KwLaJGeDIGbGjS4p9Mw\/view?usp=drivesdk\" target=\"&quot;_blank&quot;\">IntelligentGraph-PathQL and Scripting.pdf<\/a><\/span><\/p>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Genealogical Example<\/span><\/h2>\n<p class=\"\"><span style=\"font-weight: 400;\">Genealogy is a grandfather of graphs, it is, therefore, natural to organize family trees as a knowledge graph.&nbsp; A typical PathQL question to ask would then be: who are the parents of a male ancestor, born in Maidstone, of this individual, and what is that relationship?&nbsp;<\/span><\/p>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Industrial Internet of Things (IIoT) Example<\/span><\/h2>\n<p class=\"\"><span style=\"font-weight: 400;\">The Industrial Internet of Things (IIot) is best modeled as an interconnected graph of &#8216;thing&#8217; nodes. These things might be sensors producing measurements, the equipment to which the sensors are attached, or how the equipment is interconnected to form a functioning plant. However, the &#8216;intelligence&#8217; about why the plant is interconnected is what an experienced (aka intelligent, knowledgeable) process engineer offers. To support such intelligence with a knowledge graph requires answering PathQL questions such as<\/span><\/p>\n<ol class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">If the V101 bottoms pump stops how does this affect the product flow from this production unit?<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">If the FI101 instrument fails how does this affect the boiler feed temperature?<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">What upstream could possibly be affecting this stream\u2019s quality?<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">\u2026 and so on.<\/span><\/li>\n<\/ol>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Why PathQL?<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">SPARQL is a superb graph pattern query language, so why create another?<\/span><\/p>\n<p class=\"\"><span style=\"font-weight: 400;\">PathQL started out as the need to traverse the nodes and edges in a triplestore both without the benefit of SPARQL and within a scripting language of<\/span><a href=\"http:\/\/inova8.com\/bg_inova8.com\/intelligent-graph-knowledge-graph-embedded-analysis\/\"><span style=\"font-weight: 400;\">&nbsp;IntelligentGraph<\/span><\/a><span style=\"font-weight: 400;\">. IntelligentGraph works by embedding the calculations within the graph. Therefore, just like a spreadsheet calculation can access other &#8216;cells&#8217; within its spreadsheet, IntelligentGraph needed a way of traversing the graph through interconnected nodes and edges to other nodes from where relevant values can be retrieved.<\/span><\/p>\n<p class=\"\"><span style=\"font-weight: 400;\">I didn&#8217;t want to create a new language, but it was essential that the<\/span><a href=\"http:\/\/inova8.com\/bg_inova8.com\/intelligent-graph-knowledge-graph-embedded-analysis\/\"><span style=\"font-weight: 400;\"> IntelligentGraph<\/span><\/a><span style=\"font-weight: 400;\">provided a very easy way to navigate a path through a graph. It then became clear that, as powerful as SPARQL is for graph pattern matching, it can be verbose for matching path patterns. PathQL was born, but not without positive prodding from my colleague<\/span><a href=\"https:\/\/www.linkedin.com\/in\/philashworth\/\"><span style=\"font-weight: 400;\"> Phil Ashworth<\/span><\/a><span style=\"font-weight: 400;\">.<\/span><\/p>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Adding Intelligence to Graphs with Scripts<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">Typically, a graph node will have associated attributes with values, such as a stream with volumeFlow and density values. These values might have been imported from some external system or other:<\/span><\/p>\n<p class=\"\"><span style=\"font-weight: 400;\">Stream Attributes:<\/span><\/p>\n<pre class=\"\"><span style=\"font-weight: 400;\">:Stream_1<\/span>\r\n<span style=\"font-weight: 400;\">    :density \".36\"^^xsd:float ;<\/span>\r\n<span style=\"font-weight: 400;\">    :volumeFlow \"40\"^^xsd:float .\r\n:Stream_2 ....<\/span><\/pre>\n<p><span style=\"font-weight: 400;\">The \u2018model\u2019 of the streams can be captured as edges associated with the Unit:<\/span><\/p>\n<pre class=\"\"><span style=\"font-weight: 400;\">:Unit_1<\/span>\r\n<span style=\"font-weight: 400;\">    :hasProductStream :Stream_1 ;<\/span>\r\n<span style=\"font-weight: 400;\">    :hasProductStream :Stream_2 <\/span><span style=\"font-weight: 400;\">.<\/span><\/pre>\n<p class=\"\"><span style=\"font-weight: 400;\">However, most \u2018attributes&#8217; that we want to see about a thing are not measured directly. Instead, they need to be calculated from other values. This is why we end up with spreadsheet-hell: importing the raw data from the data sources into a spreadsheet simply so we can add calculated columns, the values of which are rarely exported back to the source-databases.&nbsp;<\/span><\/p>\n<p class=\"\"><span style=\"font-weight: 400;\">IntelligentGraph allows these calculations to be embedded in the graph as literals[1] with a datatype whose local name corresponds to one of the installed script languages:<\/span><\/p>\n<pre class=\"\"><span style=\"font-weight: 400;\">:Stream_1<\/span>\r\n<span style=\"font-weight: 400;\">    :massFlow<\/span>\r\n<span style=\"font-weight: 400;\">        \"_this.getFact(\u2018:density\u2019)*<\/span>\r\n<span style=\"font-weight: 400;\">        _this.getFact(\u2018:volumeFlow\u2019);\"^^:groovy <\/span><span style=\"font-weight: 400;\">.<\/span>\r\n\r\n<span style=\"font-weight: 400;\">:Unit_1<\/span>\r\n<span style=\"font-weight: 400;\">    :totalProduction<\/span>\r\n<span style=\"font-weight: 400;\">        \"<\/span><b>var totalProduction =0.0;<\/b>\r\n<b>        for(Resource stream : _this.getFacts(\u2018:hasProductStream\u2019))<\/b>\r\n<b>        {<\/b>\r\n<b>        &nbsp;&nbsp; <\/b> <b>totalProduction += stream.getFact(\u2018:massFlow\u2019);<\/b>\r\n<b>        }<\/b>\r\n<b>        return totalProduction;<\/b><span style=\"font-weight: 400;\"> \"^^:groovy <\/span><span style=\"font-weight: 400;\">.<\/span><\/pre>\n<p class=\"\"><span style=\"font-weight: 400;\">Instead of returning the object literal value (aka the script), the IntelligentGraph will return the result value for the script.<\/span><\/p>\n<p class=\"\">We can write this script even more succinctly using the expressive power of PathQL:<\/p>\n<pre class=\"\"><span style=\"font-weight: 400;\">:Unit_1<\/span> <span style=\"font-weight: 400;\"> :totalProduction<\/span> <span style=\"font-weight: 400;\"> \"<\/span><b>return _this.getFacts(\u2018:hasProductStream\/:massFlow\u2019).total();<\/b><span style=\"font-weight: 400;\"> \"^^:groovy <\/span><span style=\"font-weight: 400;\">.<\/span><\/pre>\n<h1 class=\"\"><span style=\"font-weight: 400;\">PathQL<\/span><\/h1>\n<p class=\"\"><span style=\"font-weight: 400;\">Spreadsheets are not limited to accessing just adjacent cells; neither is the IntelligentGraph. PathQL provides a powerful way of navigating from one Thing node to others. PathQL was inspired by<\/span><a href=\"https:\/\/www.w3.org\/TR\/sparql11-query\/#propertypaths\"> <span style=\"font-weight: 400;\">SPARQL and propertyPaths<\/span><\/a><span style=\"font-weight: 400;\">, but a richer, more expressive, path searching was required for the IntelligentGraph.<\/span><\/p>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Examples<\/span><\/h2>\n<p class=\"\" style=\"padding: 1em;\"><img loading=\"lazy\" class=\"alignnone size-full wp-image-3593\" src=\"https:\/\/inova8.com\/bg_inova8.com\/wp-content\/uploads\/2021\/09\/Genealogy.png\" alt=\"\" width=\"960\" height=\"400\"><\/p>\n<p class=\"\" style=\"text-align: center;\"><span style=\"font-weight: 400;\">Genealogy Example Graph<\/span><\/p>\n<p class=\"\"><span style=\"font-weight: 400;\">Examples of PathQL that explore this genealogy are as follows:<\/span><\/p>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getFact(\u201c:parent\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">will return the first parent of _this.<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getFact(\u201c^:parent\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return the first child of _this.<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getFacts(\u201c:parent\/:parent\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return the grandparents of _this.<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">this.getFacts(\u201c:parent\/^:parent\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return the siblings of _this.<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400;\"> <span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getFacts(\u201c:parent[:gender :female]\/:parent\u201d)<\/span><\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return the maternal grandparents of _this<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getFacts(\u201c:parent[:gender :female]\/:parent[:gender :male]\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return the maternal grandfather of _this.<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getFacts(\u201c:parent[:gender [ rdfs:label \u201cfemale\u201d]]\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return the mother of _this but using the label instead of the IRI.<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getFacts(\u201c:parent[eq :Peter]\/:parent[:gender :male]\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return the grandfather of _this, who is the parent of <span style=\"font-family: 'courier new', courier;\">:Peter<\/span>.<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-family: 'courier new', courier;\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">_this.getFacts(\u201c:parent[ne :Peter]\/:parent[:gender :male]\u201d)<\/span><\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return grandfathers of _this, who are not the parent of <span style=\"font-family: 'courier new', courier;\">:Peter<\/span>.<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getFacts(\u201c:parent{0,4}\/:parent[:hasLocation :maidstone]\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return all ancestors whose parent was born in a location <span style=\"font-family: 'courier new', courier;\">:maidstone<\/span><\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getPath(\u201c:parent{0,4}\/:parent[:hasLocation :maidstone]\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return the path to most recent ancestor whose parent was born in a location <span style=\"font-family: 'courier new', courier;\">:maidstone<\/span><\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getFacts(\u201c:parent{0,4}\/:parent[:hasLocation [rdfs:label \u2018Maidstone\u2019]]\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">will return all ancestors whose parent was born in a location named <span style=\"font-family: 'courier new', courier;\">\u201cMaidstone\u201d<\/span><\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getPaths(\u201c:connectedTo{1,10}[eq :BakerStreet]\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">will find all routes, starting with shortest,&nbsp; between _this and <span style=\"font-family: 'courier new', courier;\">:BakerStreet<\/span> with a maximum of 10 connections, thus all on the same line<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<ul class=\"\">\n<li style=\"font-weight: 400;\" aria-level=\"1\">\n<pre><span style=\"font-weight: 400; font-family: 'courier new', courier;\">_this.getPaths(\u201c:connectedTo{1,5}\/:changeTo{0,2}\/:connectedTo{1,5}[eq :BakerStreet]\u201d)<\/span><\/pre>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"2\"><span style=\"font-weight: 400;\">will find routes, starting with the shortest, between _this and :BakerStreet with a maximum of two changes<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h2 class=\"\"><span style=\"font-weight: 400;\">PathQL Formal Syntax<\/span><\/h2>\n<p class=\"\"><span style=\"font-weight: 400;\">The parts of a PathPattern are defined below. The formal syntax in BNF is here: PathPattern Formal Syntax<\/span><\/p>\n<h4 class=\"\"><span style=\"font-weight: 400;\">IRIRef:<\/span><\/h4>\n<p style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">The simplest pathPattern is an IRI of the predicate, property, or edge:<\/span><\/p>\n<pre style=\"padding-left: 80px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:parent<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">An unprefixed qname using the default namespace.<\/span><\/p>\n<pre style=\"padding-left: 80px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">ft:parent<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">A prefixed qname using the namespace model.<\/span><\/p>\n<pre style=\"padding-left: 80px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">&lt;http:\/\/inova8.com\/ft\/hasParent&gt;<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">A full IRI.<\/span><\/p>\n<h4 class=\"\"><span style=\"font-weight: 400;\">PathAlternative:<\/span><\/h4>\n<p style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">A pathPattern can consist of a set of alternative edges:<\/span><\/p>\n<pre style=\"padding-left: 80px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:parent|:hasChild<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">Alternative edges&nbsp; to \u2018close relatives\u2019 of the <\/span><span style=\"font-weight: 400;\">:subjectThing<\/span><span style=\"font-weight: 400;\">.<\/span><\/p>\n<h4><span style=\"font-weight: 400;\">PathSequence:<\/span><\/h4>\n<p style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">A pathPattern can consist of a sequence of edges:&nbsp;<\/span><\/p>\n<pre style=\"padding-left: 80px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:parent\/:hasChild<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">&nbsp;sequence of edges to the set of siblings of the start thing.<\/span><\/p>\n<h4><span style=\"font-weight: 400;\">Inverse Modifier:<\/span><\/h4>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">A modifier prefix to a predicate indicating that it should be navigated in the reverse direction (object\u00e0subject) instead of subject\u00e0object:<\/span><\/p>\n<pre style=\"padding-left: 80px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:parent\/^:parent<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">&nbsp;A sequence of edges to the set of siblings of the start thing since <\/span><span style=\"font-weight: 400;\">^:parent<\/span><span style=\"font-weight: 400;\"> is equivalent to <\/span><span style=\"font-weight: 400;\">:hasChild<\/span><span style=\"font-weight: 400;\">.<\/span><\/p>\n<h4 class=\"\"><span style=\"font-weight: 400;\">Reified Modifier:<\/span><\/h4>\n<p style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">A modifier prefix to a predicate indicating that it should be assumed that the subject-predicate-object is reified.<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">@:marriedTo<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">navigates from the <\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:subjectThing<\/span><span style=\"font-weight: 400;\"> to the <\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:objectThing<\/span><span style=\"font-weight: 400;\"> when the edge has been reified as:<\/span><span style=\"font-weight: 400;\">&nbsp;<\/span><\/p>\n<pre class=\"\" style=\"padding-left: 120px;\"><span style=\"font-family: 'courier new', courier;\"><span style=\"font-weight: 400;\">[]  rdf:subject <\/span><b>:subjectThing<\/b><span style=\"font-weight: 400;\"> ;<\/span><\/span>\r\n<span style=\"font-family: 'courier new', courier;\"><span style=\"font-weight: 400;\">    rdf:predicate <\/span><b>:marriedTo<\/b><span style=\"font-weight: 400;\"> ;<\/span><\/span>\r\n<span style=\"font-family: 'courier new', courier;\"><span style=\"font-weight: 400;\">    rdf:object <\/span><b>:objectThing<\/b><span style=\"font-weight: 400;\"> .<\/span><\/span><\/pre>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">Inverse modifier can also be applied to navigate from the<\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\"> :objectThing<\/span><span style=\"font-weight: 400;\"> to<\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\"> :subjectThing:<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">^@:marriedTo<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">navigates from the <\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:objectThing<\/span><span style=\"font-weight: 400;\"> to the <\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:subjectThing<\/span><\/p>\n<h4><span style=\"font-weight: 400;\">Extended Reification Modifier:<\/span><\/h4>\n<p style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">The reification type and the predicate of an extended reification:<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:Marriage@:civilPartnership<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">navigates from the <\/span><span style=\"font-weight: 400;\">:subjectThing<\/span><span style=\"font-weight: 400;\"> to the <\/span><span style=\"font-weight: 400;\">:objectThing<\/span><span style=\"font-weight: 400;\"> when the edge has been reified as a class that is a <\/span><span style=\"font-weight: 400;\">:Marriage,<\/span><span style=\"font-weight: 400;\"> which is rdfs:subClassOf rdf:Statement with a predicate of <\/span><span style=\"font-weight: 400;\">:civilPartnership<\/span><span style=\"font-weight: 400;\">. For example:<\/span><span style=\"font-weight: 400;\">&nbsp;<\/span><\/p>\n<pre class=\"\" style=\"padding-left: 80px;\"><span style=\"font-family: 'courier new', courier;\"><span style=\"font-weight: 400;\">&nbsp;<\/span><span style=\"font-weight: 400;\">[] a <\/span><b>:Marriage<\/b><\/span>\r\n<span style=\"font-family: 'courier new', courier;\"><span style=\"font-weight: 400;\">    :partner1 <\/span><b>:subjectThing<\/b><span style=\"font-weight: 400;\"> ;<\/span><\/span>\r\n<span style=\"font-family: 'courier new', courier;\"><span style=\"font-weight: 400;\">    :marriageType <\/span><b>:civilPartnership<\/b><span style=\"font-weight: 400;\"> ;<\/span><\/span>\r\n<span style=\"font-family: 'courier new', courier;\"><span style=\"font-weight: 400;\">    :partner2 <\/span><b>:objectThing<\/b><span style=\"font-weight: 400;\"> .<\/span><\/span>\r\n\r\n<span style=\"font-weight: 400; font-family: 'courier new', courier;\">:Marraige rdfs:subClassOf rdf:Statement .\r\n:partner1 rdf:subPropertyOf rdf:subject .<\/span>\r\n<span style=\"font-weight: 400; font-family: 'courier new', courier;\">:marriageType rdf:subPropertyOf rdf:predicate.<\/span>\r\n<span style=\"font-weight: 400; font-family: 'courier new', courier;\">:partner2 rdf:subPropertyOf rdf:object .<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">An inverse modifier can also be applied to navigate from the<\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\"> :objectThing<\/span><span style=\"font-weight: 400;\"> to<\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\"> :subjectThing&nbsp;<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">^:Marriage@:marriedTo<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">navigates from the <\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:objectThing<\/span><span style=\"font-weight: 400;\"> to the <\/span><span style=\"font-weight: 400;\">:<span style=\"font-family: 'courier new', courier;\">subjectThing<\/span><\/span><span style=\"font-weight: 400;\"> in the extended reification.<\/span><\/p>\n<h4 class=\"\"><span style=\"font-weight: 400;\">Dereification Modifier:<\/span><\/h4>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">Instead of navigating to the objectThing of a reification, the dereification operator navigates to the reification thing:&nbsp;<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">@:marriedTo#<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">navigates from the <\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:subjectThing<\/span><span style=\"font-weight: 400;\"> to the <\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:marriage<\/span><span style=\"font-weight: 400;\"> object.<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">@:marriedTo#\/:at<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">navigates from the <\/span><span style=\"font-weight: 400;\"><span style=\"font-family: 'courier new', courier;\">:subjectThing<\/span> <\/span><span style=\"font-weight: 400;\">to the location <\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:at<\/span><span style=\"font-weight: 400;\"> which the marriage took place<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">@:marriedTo#\/:when<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">navigates from the <\/span><span style=\"font-weight: 400;\"><span style=\"font-family: 'courier new', courier;\">:subjectThing<\/span> <\/span><span style=\"font-weight: 400;\">to the date <\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:when<\/span><span style=\"font-weight: 400;\"> the marriage took place<\/span><\/p>\n<h4><span style=\"font-weight: 400;\">Path Filter:<\/span><\/h4>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">A path filter can be applied to any point in a pathPattern to limit the subsequent paths. A path filter is like a<\/span><a href=\"https:\/\/www.w3.org\/TR\/sparql11-query\/#rPropertyListNotEmpty\"> <span style=\"font-weight: 400;\">SPARQL PropertyListNotEmpty<\/span><\/a><span style=\"font-weight: 400;\"> graph pattern. However, it includes comparison operators lt, gt etc<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:parent[:gender :male]<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">Navigates to the male parent.<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:parent[:gender :male]\/:parent[:gender :female]<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">Navigates to the paternal grandmother.<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:volumeFlow[gt \u201c50\u201d]<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">Navigates only if the value is greater than \u201c50\u201d.<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:appearsOn[eq :calc2graph1]<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">Navigates only if the objectNode value is <\/span><span style=\"font-weight: 400;\">:calc2graph1.<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:appearsOn[ rdfs:label \"Calc2Graph1\"]<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">Navigates only if the objectNode has a <\/span><span style=\"font-weight: 400;\"><span style=\"font-family: 'courier new', courier;\">rdfs:label<\/span> <\/span><span style=\"font-weight: 400;\">with value <\/span><span style=\"font-weight: 400;\">&#8220;Calc2Graph1&#8221;.<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:appearsOn[eq [ rdfs:label \"Calc2Graph1\"]]<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">Navigates only if the objectNode value is a node whose label is <\/span><span style=\"font-weight: 400;\">&#8220;Calc2Graph1&#8221;.<\/span><\/p>\n<h4 class=\"\"><span style=\"font-weight: 400;\">Cardinality:<\/span><\/h4>\n<p style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">Repeats the pathPattern between the range of minimum and maximum cardinality<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:parent{1,5}<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">Finds the 1 to 5th ancestor of the reference node.<\/span><\/p>\n<pre style=\"padding-left: 40px;\"><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:parent[:gender :male]{1,5}<\/span><\/pre>\n<p class=\"\" style=\"padding-left: 80px;\"><span style=\"font-weight: 400;\">Finds the 1 to 5th male ancestor via the male line of the reference node.<\/span><\/p>\n<h1 class=\"\"><span style=\"font-weight: 400;\">Further Example Scripts<\/span><\/h1>\n<p class=\"\"><span style=\"font-weight: 400;\">The following illustrates the IntelligentGraph scripts to perform the plant analysis example<\/span><\/p>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Return Scalar Value<\/span><\/h2>\n<pre><span style=\"font-weight: 400;\">return 40;<\/span><\/pre>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Get Related Property Value<\/span><\/h2>\n<pre class=\"\"><span style=\"font-weight: 400;\">return _this.getFact(\":<\/span><a href=\"http:\/\/inova8.com\/calc2graph\/def\/testProperty2%3e%22\"><span style=\"font-weight: 400;\">testProperty2\"<\/span><\/a><span style=\"font-weight: 400;\">).doubleValue()<\/span><\/pre>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Calculate Stream Mass Flow<\/span><\/h2>\n<pre class=\"\"><span style=\"font-weight: 400;\">var result= _this.getFact(\":volumeFlow\").floatValue()* _this.getFact(\":density\").floatValue();&nbsp; <\/span>\r\n<span style=\"font-weight: 400;\">return result;<\/span><\/pre>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Calculate Unit Mass Throughput<\/span><\/h2>\n<pre class=\"\"><span style=\"font-weight: 400;\">return _this.getFacts(\":hasProductStream\/:massFlow\").total();<\/span><\/pre>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Calculate Stream Mass Yield<\/span><\/h2>\n<pre class=\"\"><span style=\"font-weight: 400;\">var result= _this.getFact(\":massFlow\").floatValue()\/ _this.getFact(\"^:hasStream\/:massThroughput\").floatValue();&nbsp; <\/span>\r\n<span style=\"font-weight: 400;\">return result;<\/span><\/pre>\n<h2 class=\"\"><span style=\"font-weight: 400;\">Calculate Unit Mass Balance<\/span><\/h2>\n<pre class=\"\"><span style=\"font-weight: 400;\">return _this.getFacts(\":hasFeedStream\/:massFlow\").total() \r\n- _this.getFacts(\":hasProductStream\/:massFlow\").total();<\/span><\/pre>\n<h1 class=\"\"><span style=\"font-weight: 400;\">Path Navigation Functions<\/span><\/h1>\n<p><span style=\"font-weight: 400;\">The spreadsheets\u2019 secret sauce is the ability of a cell formula to access values of other cells, either individually or as a set. The IntelligentGraph provides this functionality with several methods associated with Thing, which are applicable to the _this Thing initiated for each script with the subject Thing.<\/span><\/p>\n<h3><b>Thing.getFact(String pathQL) returns Resource<\/b><\/h3>\n<p class=\"\"><span style=\"font-weight: 400;\">Returns the value of the node referenced by the pathQL, for example <span style=\"font-family: 'courier new', courier;\">\u201c<\/span><\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:volumeFlow<\/span><span style=\"font-weight: 400;\"><span style=\"font-family: 'courier new', courier;\">\u201d<\/span> returns the object value of the <\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:volumeFlow<\/span><span style=\"font-weight: 400;\"> edge relative to _this node. The pathPattern allows for more complex path navigation.<\/span><\/p>\n<h3 class=\"\"><b>Thing.getFacts(String pathQL) returns ResourceResults<\/b><\/h3>\n<p class=\"\"><span style=\"font-weight: 400;\">Returns the values of nodes referenced by the pathQL, for example \u201c<\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:hasProductStream<\/span><span style=\"font-weight: 400;\">\u201d returns an iterator for all object values of the<span style=\"font-family: 'courier new', courier;\"> :hasProductStream<\/span> edge relative to _this node. The pathPattern allows for more complex path navigation.<\/span><\/p>\n<h3><b>Thing.getPath(String pathQL) returns Path<\/b><\/h3>\n<p class=\"\"><span style=\"font-weight: 400;\">Returns the first (shortest)&nbsp; path referenced by the pathQL, for example \u201c<\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:parent{1..5}<\/span><span style=\"font-weight: 400;\">\u201d returns the path to the first ancestor of _this node. The pathQL allows for more complex path navigation.<\/span><\/p>\n<h3 class=\"\"><b>Thing.getPaths(String pathQL) returns PathResults<\/b><\/h3>\n<p class=\"\"><span style=\"font-weight: 400;\">Returns all paths referenced by the pathQL, for example<\/span> <span style=\"font-weight: 400;\">\u201c<\/span><span style=\"font-weight: 400; font-family: 'courier new', courier;\">:parent{1..5}<\/span><span style=\"font-weight: 400;\">\u201d returns an iterator, starting with the shortest path,&nbsp; for all paths to the ancestors of _this node. The pathQL allows for more complex path navigation.<\/span><\/p>\n<h3><b>Graph.getThing(String subjectIRI) returns Thing<\/b><\/h3>\n<p class=\"\"><span style=\"font-weight: 400;\">Returns a node as defined by the IRI<\/span><\/p>\n<h1 class=\"\"><span style=\"font-weight: 400;\">Script Context Variables<\/span><\/h1>\n<p><span style=\"font-weight: 400;\">Each script has access to the following predefined variables that allow the script to access the context within which it is being run.<\/span><\/p>\n<p class=\"\" style=\"padding-left: 40px;\"><b>_this<\/b><span style=\"font-weight: 400;\">, a Thing corresponding to the subject of the triples for which the script is the object.&nbsp; Since this is available, helper functions are provided to navigate edges to or from this \u2018thing\u2019 below:<\/span><\/p>\n<p style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">_<\/span><b>property<\/b><span style=\"font-weight: 400;\">, a Thing corresponding to the predicate or property of the triples for which the script is the object.<\/span><\/p>\n<p class=\"\" style=\"padding-left: 40px;\"><b>_customQueryOptions<\/b><span style=\"font-weight: 400;\">, a HashMap&lt;String, Value&gt; of name\/value pairs corresponding to the pairs of additional arguments to the SPARQL extension function. These are useful for passing application-specific parameters.<\/span><\/p>\n<p class=\"\" style=\"padding-left: 40px;\"><b>_builder<\/b><span style=\"font-weight: 400;\">, a<\/span><a href=\"https:\/\/rdf4j.org\/javadoc\/latest\/org\/eclipse\/rdf4j\/model\/util\/ModelBuilder.html\"> <span style=\"font-weight: 400;\">RDF4J graph builder<\/span><\/a><span style=\"font-weight: 400;\"> object allowing a graph to be constructed (and manipulated) within the script. A graph cannot be returned from a SPARQL function. However the IRI of the graph can be returned, and any graph created by a script will be persisted.<\/span><\/p>\n<p class=\"\" style=\"padding-left: 40px;\"><b>_tripleSource<\/b><span style=\"font-weight: 400;\">, the<\/span><a href=\"https:\/\/rdf4j.org\/javadoc\/latest\/org\/eclipse\/rdf4j\/query\/algebra\/evaluation\/TripleSource.html\"> <span style=\"font-weight: 400;\">RDF4J TripleSource<\/span><\/a><span style=\"font-weight: 400;\"> to which the subject, predicate, triple belongs.<\/span><\/p>\n<h1><span style=\"font-weight: 400;\">PathQL BNF<\/span><\/h1>\n<p><span style=\"font-weight: 400;\">The formal syntax of the PathPattern is defined as follows using ANTLR4 BNF:<\/span><\/p>\n<pre class=\"\">grammar PathPattern;\r\n\r\n\/\/ PARSER RULES\r\nqueryString     : pathPattern queryOptions? EOF ;\r\nqueryOptions    : ( queryOption )+;\r\nqueryOption     : KEY '=' literal ('^^' type )?;\r\ntype            : qname;\r\npathPattern     : binding ('\/'|'&gt;') pathPatterns&nbsp; #boundPattern\r\n&nbsp;               | binding&nbsp; #matchOnlyPattern\r\n&nbsp;               | pathPatterns&nbsp; #pathOnlyPattern;\r\nbinding         : factFilterPattern&nbsp; ;\r\npathPatterns    : pathEltOrInverse cardinality?&nbsp; #Path&nbsp; \r\n                | pathPatterns '|'&nbsp; pathPatterns&nbsp; #PathAlternative&nbsp; \r\n                | pathPatterns ('\/'|'&gt;')&nbsp; pathPatterns&nbsp; #PathSequence\r\n                | negation? '(' pathPatterns ')'&nbsp; cardinality? #PathParentheses;\r\ncardinality     : '{'&nbsp; INTEGER (',' ( INTEGER )? )?&nbsp; '}'&nbsp; ;\r\nnegation        : '!';\r\npathEltOrInverse: negation? INVERSE? predicate&nbsp; ;\r\npredicate       : ( reifiedPredicate \r\n                |  predicateRef \r\n                |  rdfType \r\n                |  anyPredicate ) factFilterPattern? ;\r\nanyPredicate    : ANYPREDICATE ;\r\nreifiedPredicate: iriRef? REIFIER predicateRef&nbsp; factFilterPattern?&nbsp; dereifier? ;\r\npredicateRef    : IRI_REF&nbsp; | rdfType&nbsp; |&nbsp; qname | pname_ns ;\r\niriRef&nbsp;         : IRI_REF |&nbsp; qname | pname_ns ;&nbsp; \r\ndereifier       : DEREIFIER ;\r\nfactFilterPattern: '['&nbsp; propertyListNotEmpty &nbsp; ']';\r\npropertyListNotEmpty: verbObjectList ( ';' ( verbObjectList )? )* ;&nbsp; \r\nverbObjectList  : verb objectList;\r\nverb            : operator | pathEltOrInverse ;\r\nobjectList      : object ( ',' object )*;\r\nobject          : iriRef&nbsp; | literal | factFilterPattern | BINDVARIABLE ;\r\nqname           : PNAME_NS PN_LOCAL; \r\npname_ns        : PNAME_NS ;&nbsp;&nbsp; \r\nliteral         : (DQLITERAL | SQLITERAL) ('^^' (IRI_REF |&nbsp; qname) )? ;&nbsp; \r\noperator        : OPERATOR ;\r\nrdfType         : RDFTYPE ;\r\n\r\n\/\/ LEXER RULES\r\nKEY             : '&amp;' [a-zA-Z]+ ;&nbsp; \r\nINTEGER         : DIGIT+ ; \r\nBINDVARIABLE    : '%' DIGIT+ ;\r\nfragment\r\nDIGIT           : [0-9] ;&nbsp; \r\nINVERSE         : '^';\r\nREIFIER         : '@';\r\nDEREIFIER       : '#';\r\nRDFTYPE         : 'a';\r\nANYPREDICATE    : '*' ;\r\nOPERATOR        : 'lt'|'gt'|'le'|'ge'|'eq'|'ne'|'like'|'query'|'property';\r\nDQLITERAL       : '\"' (~('\"' | '\\\\' | '\\r' | '\\n') | '\\\\' ('\"' | '\\\\'))* '\"';\r\nSQLITERAL       : '\\'' (~('\\'' | '\\\\' | '\\r' | '\\n') | '\\\\' ('\\'' | '\\\\'))* '\\'';\r\nIRI_REF         : '&lt;' ( ~('&lt;' | '&gt;' | '\"' | '{' | '}' | '|' | '^' | '\\\\' | '`') | (PN_CHARS))* '&gt;' ;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; \r\nPNAME_NS        : PN_PREFIX? (':'|'~')&nbsp; ;&nbsp;&nbsp; \r\nVARNAME         : '?' [a-zA-Z]+ ;\r\nfragment\r\nPN_CHARS_U      : PN_CHARS_BASE | '_'&nbsp; ;\r\nfragment&nbsp;&nbsp; \r\nPN_CHARS        : PN_CHARS_U\r\n &nbsp;&nbsp;           &nbsp; | '-'\r\n             &nbsp;&nbsp; | DIGIT&nbsp; ;\r\nfragment\r\nPN_PREFIX       : PN_CHARS_BASE ((PN_CHARS|'.')* PN_CHARS)? ;\r\nPN_LOCAL        : ( PN_CHARS_U | DIGIT ) ((PN_CHARS|'.')* PN_CHARS)? ;\r\nfragment\r\nPN_CHARS_BASE   : 'A'..'Z'\r\n                | 'a'..'z'\r\n                | '\\u00C0'..'\\u00D6'\r\n                | '\\u00D8'..'\\u00F6'\r\n                | '\\u00F8'..'\\u02FF'\r\n                | '\\u0370'..'\\u037D'\r\n                | '\\u037F'..'\\u1FFF'\r\n                | '\\u200C'..'\\u200D'\r\n                | '\\u2070'..'\\u218F'\r\n                | '\\u2C00'..'\\u2FEF'\r\n                | '\\u3001'..'\\uD7FF'\r\n                | '\\uF900'..'\\uFDCF'\r\n                | '\\uFDF0'..'\\uFFFD' ;\r\nWS  : [ \\t\\r\\n]+ -&gt; skip ;&nbsp;\r\n\r\n\r\n<\/pre>\n<p class=\"\"><span style=\"font-weight: 400;\">[1]&nbsp; <\/span><span style=\"font-weight: 400;\">SCRIPT Languages<\/span><\/p>\n<p class=\"\"><span style=\"font-weight: 400;\">In this case, the script uses Groovy, but any<\/span><a href=\"https:\/\/docs.oracle.com\/javase\/9\/scripting\/java-scripting-api.htm#JSJSG109\"> <span style=\"font-weight: 400;\">Java 9 compliant<\/span><\/a><span style=\"font-weight: 400;\"> scripting language can be used, such as JavaScript, Python, Ruby, and many more.<\/span><\/p>\n<p class=\"\"><span style=\"font-weight: 400;\">By default, JavaScript, Groovy, Python JAR are installed. The complete list of compliant languages is as follows<\/span><\/p>\n<p class=\"\" style=\"padding-left: 40px;\"><span style=\"font-weight: 400;\">AWK, BeanShell, ejs, FreeMarker, Groovy, Jaskell, Java, JavaScript, JavaScript (Web Browser), Jelly, JEP, Jexl, jst, JudoScript, JUEL, OGNL, Pnuts, Python, Ruby, Scheme, Sleep, Tcl, Velocity, XPath, XSLT, JavaFX Script, ABCL, AppleScript, Bex script, OCaml Scripting Project, PHP, Python, Smalltalk, CajuScript, MathEclipse<\/span><\/p>\n<p class=\"\">&nbsp;<\/p>\n<pre>&nbsp;<\/pre>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>PathQL simplifies finding paths through the maze of facts within a \u00a0KnowledgeGraph\u00a0. Used within \u00a0IntelligentGraph\u00a0 scripts it allows data analysis to be embedded within the graph, rather than requiring graph data to be exported to an analysis engine. Used with \u00a0IntelligentGraph Jupyter Notebooks\u00a0 it provides powerful data analytics<\/p>\n","protected":false},"author":1,"featured_media":3590,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"bgseo_title":"","bgseo_description":"","bgseo_robots_index":"index","bgseo_robots_follow":"follow","_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0},"categories":[50],"tags":[43,40,35,51,52,54,55,53,56,44],"_links":{"self":[{"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/posts\/2770"}],"collection":[{"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/comments?post=2770"}],"version-history":[{"count":51,"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/posts\/2770\/revisions"}],"predecessor-version":[{"id":3619,"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/posts\/2770\/revisions\/3619"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/media\/3590"}],"wp:attachment":[{"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/media?parent=2770"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/categories?post=2770"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/inova8.com\/bg_inova8.com\/wp-json\/wp\/v2\/tags?post=2770"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}