Reflection/ Thoughts in OpenNARS for Application similar to OpenNARS Java edition

49 views
Skip to first unread message

stephen clark

unread,
Jan 1, 2022, 3:04:08 PM1/1/22
to open-nars
Hi,

In my testing of the OpenNARS Java edition I noticed that there were
extra "thoughts" from NARS in the output experience file.

I saw several "thoughts" like "wonder, believe and satisfied".

Is this level of reflection / thoughts available in OpenNARS for
Application?


thanks

Stephen


robe...@googlemail.com

unread,
Jan 3, 2022, 1:39:51 AM1/3/22
to open...@googlegroups.com
Hello Stephen,

what you saw as "wonder, believe and satisfied" were NAL-9 operator execution. NAL-9 are basically "higher level thought" processes, think of it as the ability that it can think thoughs about thoughts.
This NAL-9 capability is not yet present in ONA nor will be present for some time (months/years).

Virenfrei. www.avg.com

--
You received this message because you are subscribed to the Google Groups "open-nars" group.
To unsubscribe from this group and stop receiving emails from it, send an email to open-nars+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/open-nars/615b474f-23af-71eb-996c-bf92cdcd0e5b%40gmail.com.

stephen clark

unread,
Jan 3, 2022, 9:41:27 AM1/3/22
to open...@googlegroups.com


Is there a version of OpenNARS Java edition that allows command line or UDP interface so that I could use these new NAL-9 features?

I found this link ( https://github.com/opennars/opennars/wiki/NarNode,-communication-between-reasoners-over-UDP )but no "narnode.jar" file in any of the releases?

Can someone point me to a place where I  can download this file?

I am looking for a non gui interface to OpenNars so that I can use these "higher level thought" processes in some of my programming tasks.

robe...@googlemail.com

unread,
Jan 3, 2022, 11:36:41 AM1/3/22
to open...@googlegroups.com

robe...@googlemail.com

unread,
Jan 3, 2022, 11:40:05 AM1/3/22
to open...@googlegroups.com
You just have to download the required packages as described in the readme.
Then you need to load the class with maven parameters (I believe) to start it with all the required java libraries.

stephen clark

unread,
Jan 3, 2022, 4:04:18 PM1/3/22
to open...@googlegroups.com


I was able to get the command line version working by calling the "shell" class as follows:

C:\projects\OpenNARS304\bin_lab>java -cp opennars-lab-3.0.4-SNAPSHOT.jar org.opennars.main.Shell  null null someStatements.txt 1000


But I was not able to get a narsnode to work with this command line on windows:

C:\projects\OpenNARS304\bin_lab>java -cp opennars-lab-3.0.4-SNAPSHOT.jar org.opennars.main.Shell  null null null null 64001 127.0.0.1 64002 0.5 null True

Patrick Hammer

unread,
Jan 12, 2022, 1:45:40 PM1/12/22
to open-nars
Hi Stephen!

it should be fine. If it still did not work, please make sure to allow the UDP ports in the Windows firewall.

"In my testing of the OpenNARS Java edition I noticed that there were 
extra "thoughts" from NARS in the output experience file. 
I saw several "thoughts" like "wonder, believe and satisfied". 
Is this level of reflection / thoughts available in OpenNARS for 
Application?"

No since it was highly experimental and did way more harm than good thus far, but it can be removed by using the mvpConfig we used for the Cisco projects.
v3.0.4 relates mental ops with external events mostly and hence forms superstitions, while mental operators should actually be correlated with internal events primarily (though not only).
The latter I might add in ONA at some point as I think it could be useful. Since activity in the OpenNARS repository is very low currently, I actually expect this to appear in a useful form in ONA first, though also the new OpenNARS architecture supports it in theory (just not in practice yet). For this to work well in practice, temporal compounding needs to be effective, but the Java versions struggle with this thus far.
v3.0.4 was ok for input events, and the new Java version with the new architecture tries to extent this with a more general control structure with little success thus far (with temporal compounding for input and derivations) which details need to be figured out, tested, and tuned over a year or so if comparable performance like v3.0.4 for external events should be reached while also benefiting from the compositions with internal events at the same time. Not sure who will do this, but so far v3.0.4 is still the best Java version and I have moved on to ONA in my journey to make NARS practical.

Best regards,
Patrick

stephen clark

unread,
Jan 12, 2022, 7:26:35 PM1/12/22
to open...@googlegroups.com

Patrick,

RE: No since it was highly experimental and did way more harm than good thus far...

I found the implementation quite useful so please keep it in OpenNARS and consider adding it in ONA.


I was reviewing the java code in this file ( https://github.com/opennars/opennars/blob/master/src/main/java/org/opennars/plugin/mental/InternalExperience.java ) and I noticed several mental operations ( "^remind","^doubt","^consider","^evaluate","^hesitate","^wonder","^belief","^want" ) that could be used to provide feedback to the internal processes.

I am reminded of the "internal monologue" presentation by Antonio Chella ( https://www.youtube.com/watch?v=zrC9VA6TKBs ) at the AGI conference a couple months ago. I found the presentation quite illuminating on how "mental operations" could be used in a robot.



I could not find a NAL-9 specification for these "mental operations" on the Open NARS sites.

If I could find this specification I would try to add this functionality to the code base.

The question is which code base would be best to update?


Stephen

Patrick Hammer

unread,
Jan 19, 2022, 10:06:10 AM1/19/22
to open-nars
Hi Stephen!

"I found the implementation quite useful so please keep it in OpenNARS and consider adding it in ONA."

I'm glad it was useful to you. To the system however it's mostly a drain, making it fail in many more multistep reasoning and decision making examples.
While the goal of introspective reasoning is not in improving efficiency in terms of less amount of reasoning steps carried out, the goal definitely is improving flexibility and overall cognitive abilities of the system via extra reasoning, introspection in the human mind serves a strong purpose!
What I want from NAL-9 is (among others):
- Learn to redirect mental resources in a problem-specific way to become more effective in solving similar instances of the problem in the future. (^consider, ^remind, ^remember etc.)
- Ability to ignore evidence from beliefs which don't seem to hold up anymore due to some suspected reason. (^doubt)
- Ability to make assumptions and generally building of beliefs which can be useful for a task (^assume, ^believe)
- Ability to recognize when wanting something or repeatedly failing to achieve something, or when relevant knowledge seems missing. (^want, ^anticipate, ^wonder)

Even though the mental operators do exist in a very early form in v3.0.4, I don't think it is able of any of the list entries I mentioned.
Temporal and procedural reasoning needs to be mature and the control system needs to work properly for this to become possible.

"The question is which code base would be best to update?"

Either ONA or the new OpenNARS version ( v3.1.2, https://github.com/opennars/opennars_v3.1.2 ), which is an attempt to solve the severe control issues of v3.0.4, though the budget system which needs revision has not been touched yet. If you need some help with implementing it, also feel free to join our #nars channel on freenode IRC and element.io!

Best regards,
Patrick
Reply all
Reply to author
Forward
0 new messages