- Extends the meta-interpreter with capabilities for collapsing chains
of base predicate queries into a single SPARQL query
- lazy evaluation of conjunction of multiple base predicates causes
removal of certain meta interpreter rules
- changed PartialInstanciation._generateBindings to use more efficient
and concise algorithm
- added FuXi.Network.Network.reportSize method which reports a summary
of the RETE network (size of largest memories, etc.)
- fix to deprecation warnings regarding use of md5 (use hashlib if available)
- Added dict with set operations to FuXi.Rete.Util
- added copy method to FuXi.Syntax.InfixOWL.BooleanClass
- added registerReteAction method to Network instances
There is only one [3] more step left before the top-down / SLD
reasoner can be completely deprecated with the BFP reasoner
As usual, comments / issues / etc. are welcome!
[1] http://code.google.com/p/fuxi/source/detail?r=332ea68ad3
[2] http://pypi.python.org/pypi/FuXi/1.2.production
[3] http://code.google.com/p/fuxi/issues/detail?id=37
easy_install-2.5 fuxiProcessing fuxierror: Couldn't find a setup script in /Users/onewnan/Temp/FuXi/Install/fuxi
...======================================================================
ERROR: testOwl (__main__.OwlTestSuite)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/Users/Shared/workspaces/workspace/fuxi/test/testOWL.py", line 361, in testOwl
conclusionFile)
File "/Users/Shared/workspaces/workspace/fuxi/test/testOWL.py", line 248, in MagicOWLProof
timing=self.calculateEntailments(factGraph)
File "/Users/Shared/workspaces/workspace/fuxi/test/testOWL.py", line 152, in calculateEntailments
self.network.feedFactsToAdd(generateTokenSet(factGraph))
File "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/Network.py", line 604, in feedFactsToAdd
self.addWME(token)
File "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/Network.py", line 594, in addWME
alphaNode.activate(wme.unboundCopy())
File "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/AlphaNode.py", line 322, in activate
memory.successor.propagate(memory.position,aReteToken.debug,wme=aReteToken)
File "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/BetaNode.py", line 660, in propagate
self._activate(PartialInstanciation([wme],consistentBindings=wme.bindingDict.copy()),debug)
File "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/BetaNode.py", line 607, in _activate
self.network.fireConsequent(partInstOrList,self,debug)
File "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/Network.py", line 553, in fireConsequent
self.addWME(inferredToken)
File "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/Network.py", line 594, in addWME
alphaNode.activate(wme.unboundCopy())
File "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/AlphaNode.py", line 322, in activate
memory.successor.propagate(memory.position,aReteToken.debug,wme=aReteToken)
File "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/BetaNode.py", line 652, in propagate
print self.clauseRepresentation()
File "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/BetaNode.py", line 557, in clauseRepresentation
return repr(first(self.rules).formula)
AttributeError: 'NoneType' object has no attribute 'formula'
----------------------------------------------------------------------
Ran 1 test in 0.798s
FAILED (errors=1)
] "/Users/Shared/workspaces/workspace/fuxi/build/lib/FuXi/Rete/BetaNode.py",
] line 557, in clauseRepresentation
]
] return repr(first(self.rules).formula)
]
] AttributeError: 'NoneType' object has no attribute 'formula'
]
] ...
]
] Entered a defect report on this.
This is the same as
http://code.google.com/p/fuxi/issues/detail?id=40
which contains a patch.
Not sure precisely why this happens (e.g. in what circumstances
an empty rule set ends up there...
Cheers,
-w
--
William Waites
http://eris.okfn.org/ww/foaf#i
9C7E F636 52F6 1004 E40A E565 98E3 BBF3 8320 7664