Yeah, I'm pretty sure you're right. Like Einstein and relativity, I actually thought of what I did wrong while riding my bike home (OK, not quite the same, but doesn't SPIN have something to do with quarks and quantum theory ;-)
Anyway, I recently changed to not including my A-Box model in the call to class2query for efficiency, but in the process removed all the spin stuff too. I'll give it a go tomorrow. Thanks! Jeff On May 24, 4:23 pm, Holger Knublauch <[email protected]> wrote: > Jeff, > > I believe your model needs to import (have a sub-graph for) spin.rdf - this > defines spin:_this. If you want to avoid this, there is a TBC preference on > the SPIN page to switch off reusing shared variables, and have blank nodes > each time. > > Regards, > Holger > > On May 25, 2010, at 4:49 AM, Schmitz, Jeffrey A wrote: > > > > > > > Hello, > > I’m using the SPIN API (latest version) to try to execute a spin:rule on > > a model (_model). The actual rule predicate being processed is a > > subproperty of spin:rule and is defined as follows in my Ontology: > > > CONSTRUCT { > > ?this Advise:failureRate 10.0 . > > } > > WHERE { > > ?this Advise:failureRate ?rate . > > } > > > (This is just a dummy query to see if I can get the spin rules stuff > > working). > > > In my code I call: > > > SPINInferences.run(_model, spinInfModel, > > _spinRulesClass2QueryMap, initialTemplateBindings, > > exp, > > _spinRuleStats, true, inferenceType.inferenceProp(), > > null, null); > > > I write the _model to file just before the call, and it looks good (the > > above query works correctly on it when run in TBC). However, when the code > > runs I don’t get any results. > > > One interesting thing is I print out the query inside > > SPINInferences.runQueryOnClass using > > > System.out.println(arq.toString()); > > > And it lists: > > > CONSTRUCT > > { spin:_this Advise:failureRate 10.0 .} > > WHERE > > { ?this rdf:type ?TYPE_CLASS . > > spin:_this Advise:failureRate ?rate > > } > > > So the class2Query stuff seems to be finding my spin:rule predicate ok, but > > the query looks a little strange with the spin:_this. > > > I also print out the query solution map (i.e. bindings): > > > TYPE_CLASS =http://www.boeing.com/IVHM/Advise.owl#Failure > > > The above query seems a little funny since (as far as I can tell) it is > > passed directly into the ARQ function of qexec.execConstruct(), which I’m > > guessing isn’t going to match up spin:_this with anything in my model. Any > > ideas what’s going on here? > > > Thanks, > > Jeff > > > -- > > You received this message because you are subscribed to the Google > > Group "TopBraid Suite Users", the topics of which include TopBraid Composer, > > TopBraid Live, TopBraid Ensemble, SPARQLMotion and SPIN. > > To post to this group, send email to > > [email protected] > > To unsubscribe from this group, send email to > > [email protected] > > For more options, visit this group at > >http://groups.google.com/group/topbraid-users?hl=en > > -- > You received this message because you are subscribed to the Google > Group "TopBraid Suite Users", the topics of which include TopBraid Composer, > TopBraid Live, TopBraid Ensemble, SPARQLMotion and SPIN. > To post to this group, send email to > [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group > athttp://groups.google.com/group/topbraid-users?hl=en -- You received this message because you are subscribed to the Google Group "TopBraid Suite Users", the topics of which include TopBraid Composer, TopBraid Live, TopBraid Ensemble, SPARQLMotion and SPIN. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/topbraid-users?hl=en
