Have you managed to get the correct answer yet?
Almost, I bumped into a small delay this weekend (a bug-fix caused the core to run a little faster, revealing a few new deadlock situations, which had to be fixed to get back to testing). This week, the bugs should be removed from the count algorithm if there are no more unexpected issues. Off course, I will than have to move the search code over to the noun resolvers, which don't have the fancy search yet.
Have you tried using easier input:
EG:
User: I have 2 hands.
User: Each of my hands, has 5 fingers.
User: How many fingers do have on 2 hands?
Less statements are not equal to easier for AICI. It doesn't matter how many or few you give for the algorithm. What's important is the structural complexity of the statements, their order, completeness and if it can be learned ('on' is not yet handled correctly by aici and this is a word who's meaning can't be learned, it needs to be coded) . Also, I wanted to test a few more (hidden) situations that aren't included in your statements. Here's a detailed description of each statement:
- a human's components are bodyparts: AICI doesn't know the word bodypart. With this statement, we make bodypart behave like 'component. Also, this is used to check if AICI can find plurals in unknown words.
- a hand is a bodypart: the word 'hand' was unknown.
-fingers are bodyparts: finger is unknown. This is also to test if the system correctly cancels out the 2 undefined plurals
-a hand has 5 fingers, a human has 2 hands: the actual data that needs to be counted. this tests if it is stored correctly
-i am a human: this statement is very important: it binds the concrete 'me' to the previous abstract knowledge. It is used to test if AICI can correctly link abstract with concrete. In your example, there is a direct link between 'i' and hands. With these statements, you don't have this, which is an added layer of complexity that I wanted to test.
Also have you tried putting in some basic mathematics.
EG:
User: what is two plus two.
This is actually easier to implement compared to the counter. The network has mathematical instructions (+-/*%), though AICI doesn't yet know the word 'plus'. Once it know's this, it is simply a matter of attaching the 'add' instructions.