Semaphore 4.x ontology model not flushing properly when published

The first ontology I built/published called “Locations” was rough. So, I built/published a better one called “Organizations.” I deleted the first ontology from the Ontology Editor (OE), but my Search Application Framework (SAF) search dialog box seemed to continue autosuggesting old ontology terms found “in Locations”

Bad Search Autosuggest

I then realized I was unaware of a way to formally flush an old ontology model from the Classification Server (CS) or Semantic Enhancement Server (SES). So, I went to Smartlogic’s Portal and looked through the knowledge base articles related to the Semaphore Publisher. Although I did see a “purge” command line switch, the command 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 seem to go away when I published.

They then offered the idea that a change in the model name might leave some old rules lingering around. Well, I had not changed the name of the old model – I had just deleted it. But, 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

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

… which was reflected in the SPARQL Editor as well:

SPARQL Editor with URIs

With this in mind, Smartlogic recommended I restart the Tomcat service supporting the Semaphore Workbench Ontology Editor. They had heard of Tomcat not flushing deleted terms properly. Indeed, that seemed to solve the SES autosuggest problem. The current schema appears as designed.

Good Search Autosuggest

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 thoughts on “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.

    • 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

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s