Skip to content

Instantly share code, notes, and snippets.

Kendall Clark kendall

Block or report user

Report or block kendall

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
kendall / graph_shortestpath_reasoning.ttl
Created Jan 14, 2014
Stardog 2.2 graph analytics embedded in SPARQL queries
View graph_shortestpath_reasoning.ttl
# graph for shortest path with reasoning
@prefix rule: <tag:stardog:api:rule:> .
@prefix : <urn:test:> .
@prefix g: <tag:stardog:api:property:graph:> .
# the graph
:one :to :two .
:one :to :four .
:two :to :four .
:two :to :five .
View spacemacs.el
;; -*- mode: dotspacemacs -*-
(defun dotspacemacs/layers ()
dotspacemacs-configuration-layers `(
(colors :variables
colors-enable-rainbow-identifiers t
colors-enable-nyan-cat-progress-bar t)
kendall / gist:1732851
Created Feb 3, 2012
Stardog 0.9 Admin Shell
View gist:1732851
-> % java -cp dist/lib/stardog-cli.jar com.clarkparsia.stardog.cli.console.StardogConsole
INFO: Stardog Server running on local:stardog
> help
Stardog 0.7.4 command line client
Type 'help <cmd>' or '<cmd> -h/--help' to print the usage information for a specific command
Available commands:
kendall / applicationContext.xml
Created Jul 30, 2011
View applicationContext.xml
<bean name="dataSource" class="com.clarkparsia.stardog.ext.spring.DataSourceFactoryBean">
<property name="to" value="testdb"/>
<property name="createIfNotPresent" value="true"/>
<bean name="template" class="com.clarkparsia.stardog.ext.spring.SnarlTemplate">
<property name="dataSource" ref="dataSource"/>
<bean name="importer" class="com.clarkparsia.stardog.ext.spring.DataImporter">
kendall /
Created Jul 30, 2011
Spring for Stardog fragments
String sparql = "CONSTRUCT { ?a <urn:test:new> ?b } WHERE { ?a <urn:test:p> ?b }";
List<Map<String,String>> results = snarlTemplate.construct(sparql, new GraphMapper<Map<String,String>>() {
public Map<String, String> mapRow(Statement next) {
Map<String,String> map = new HashMap<String,String>();
map.put(next.getSubject().stringValue(), next.getObject().stringValue());
return map;
kendall /
Created Jul 30, 2011
Spring Select fragment
String sparql = "SELECT ?a ?b WHERE { ?a <urn:test:b> ?b } LIMIT 5";
List<Map<String,String>> results = snarlTemplate.query(sparql, new RowMapper<Map<String,String>>() {
public Map<String,String> mapRow(BindingSet bindingSet) {
Map<String,String> map = new HashMap<String,String>();
map.put("a", bindingSet.getValue("a").stringValue());
map.put("b", bindingSet.getValue("b").stringValue());
return map;
kendall / thrift-output-osx
Created Oct 25, 2010
Here's the 'brew install -v thrift' output on my OSX box where thrift (0.5) won't compile
We couldn’t find that file to show.
[$]> ; wget --header "Accept:text/turtle" -O ps-desc.ttl
View pellet-server-advert.js
"ps-discovery": {
"response-mimetype": [
"endpoint": {
"http-methods": ["GET"],
You can’t perform that action at this time.