Semaphore 4.x ontology model not flushing properly when published

December 12, 2015

The “in Locations” suggestions should have been “in Organzations,” so some sort of flush was involved somewhere.

bad search autosuggest - Semaphore 4.x ontology model not flushing properly when published

Unaware of how flush an old ontology model from the Classification Server (CS) or Semantic Enhancement Server (SES), I went to Smartlogic’s Portal and looked through the knowledge base articles related to the Semaphore Publisher. I saw a “purge” command line switch, but this applied only to Windows. There were no “drop” or “purge” switches available to the Publisher from the Linux command line.

Emails with Smartlogic suggested that publishing should automatically update CS and SES assuming the publisher configuration has not changed. But, “should” was the operative word here – the old stuff did not go away.

They suggested that a change in the model name might leave some old rules lingering around. But, I had not changed the name of the old model – I had just deleted it. And, if this idea applied to the renaming of Concept Schemes in model, then the issue may well have not stemmed from an old lingering model at all.

Maybe search suggestions were returning instances from the current Organizations model? I did have a Concept Scheme in the current model called “Locations” at one time with a few instances. After deleting those instances, I had renamed the Concept Scheme to “Facilities” and added a new set of instances.

concept schema - Semaphore 4.x ontology model not flushing properly when published

Both old and new places began showing up as suggestions in the search box thereafter. Oddly, the old ones were showing up after typing one or two characters, while the new ones required at least four characters before showing up.

I was publishing only the “Organization” ontology sure enough, but looking more closely in the editor, it was clear that the change in Concept Scheme from “Locations” to “Facilities” had changed only the concept’s label rather than the URI in the back-end triplestore (see Note below) …

facilities schema - Semaphore 4.x ontology model not flushing properly when published

… which was reflected in the SPARQL Editor as well:

sparql editor with uris - Semaphore 4.x ontology model not flushing properly when published

With this in mind, Smartlogic suggested that the Tomcat service running the Semaphore Workbench Ontology Editor may not be flushing the deleted terms properly. Restarting Tomcat solved the SES autosuggest problem, and the correct schema appeared as expected.

good search autosuggest - Semaphore 4.x ontology model not flushing properly when published

Note: the URI remains intact, because the model is published as a linked data resource by default. Smartlogic has debated internally about this default, and allowing modelers to edit the URI to correct things when they change their minds might be a future enhancement. In the meantime, it “may” be possible to modify the URI using the Ontology Editor’s built-in SPARQL editor.

2 Replies to “Semaphore 4.x ontology model not flushing properly when published”

  1. it’s funny you call this an ontology. Semaphore is an ontology management tool, but most people use it for taxonomy management. anyway, thanks for sharing.

    1. I don’t know how most people use Semaphore, but the latest version, based on RDF graph standards, makes building ontologies rather unavoidable. This post represents a very early stage in dev, which started out with terms and taxonomies. It’s gone way beyond that, as it should.

Leave a Reply

Your email address will not be published. Required fields are marked *