User Tools

Site Tools


public:t-720-atai:atai-22:engineering_assignment_2

This is an old revision of the document!


ATAI-22 Reykjavik University



Engineering Assignment 2:

Knowledge Transfer Via OpenNARS for Applications (ONA)


The aim of this assignment is to introduce you to a general-purpose AI system, OpenNARS-for-Applications (ONA), and to familiarize you with how ONA transfers and generalizes knowledge.

Introduction to ONA and some examples

ONA is a general machine intelligence (GMI) aspiring system created by Patrick Hammer which is derived from Pei Wang’s Non-Axiomatic Reasoning System (NARS). To interact with ONA (or NARS) the language narsese was developed to feed information to/ receive information from NARS/ ONA). To get a first grasp on narsese (or NAL) please refer to the slides from 2018 by Xiang Li: nars-tutorial.pdf. You can also run the following examples to see how basic knowledge transfer based on abduction, analogy, comparison, and difference occurs in ONA/NARS.

Abduction on properties, deriving a generic behavior: https://github.com/opennars/OpenNARS-for-Applications/blob/master/examples/nal/duck.nal

Higher-order abduction with behavior usage in a circus setting: https://github.com/opennars/OpenNARS-for-Applications/blob/master/examples/nal/circus.nal

Deriving that keys do open doors: https://github.com/opennars/OpenNARS-for-Applications/blob/master/examples/nal/door.nal

Applying given similarity and equivalence: https://github.com/opennars/OpenNARS-for-Applications/blob/master/examples/nal/clapwave0.nal https://github.com/opennars/OpenNARS-for-Applications/blob/master/examples/nal/clapwave1.nal

Deriving an applicable behavior from the presence of a property: https://github.com/opennars/OpenNARS-for-Applications/blob/master/examples/nal/door2.nal

And maybe diagnostics examples: (these will soon also work effectively when there are dozens of properties assigned to each instance) https://github.com/opennars/OpenNARS-for-Applications/blob/master/examples/nal/diagnostic.nal

A more advanced example, numerical comparison carried out by NARS, with induction of a related behavior: https://github.com/opennars/OpenNARS-for-Applications/blob/master/examples/nal/whatwarmer.nal

And learning about the typical color of plants and oceans from instances, then comparing them: https://github.com/opennars/OpenNARS-for-Applications/blob/master/examples/nal/greenplant.nal

If instead of cases showing the inference capabilities you want an environment where an agent shows knowledge transfer while operating, I will soon have more on that. This is something that usually demands goals in a domain to change, or behaviors to learn which generalize to new instances to be shown effectively. An example here is https://github.com/opennars/OpenNARS-for-Applications/blob/master/examples/nal/example4.nal which corresponds to the following experiment which I initially made work with OpenNARS: https://www.youtube.com/watch?v=e92RV1BBeKU

How to build ONA on your system

Please follow the installation steps described in https://github.com/opennars/OpenNARS-for-Applications to build ONA on your system. If you do not have a Linux/ Ubuntu System installed on your computer please inform yourself about how to get ONA running. You can use a VM or Linux for Windows (presumably) for example, but please inform yourself and ask if something does not work early enough! Once you have ONA set up correctly (try the evaluation as explained in the github link) you can get started with the above examples.


Your Task:

Your task is to use what you learn from the above slides and examples in order to create three examples where the knowledge transfer capability of ONA can be shown according to the following instructions.

1. Knowledge transfer via shared properties. Your first task is to write a set of narsese statements that emulate three objects (a sphere, a cube and a cylinder) and a robotic hand that can grab the objects. Each object has three different properties including color, weight, and softness. The objects might have shared properties, e.g. both the cube and the sphere can have a blue color. Assign the properties to the objects such that the cube has more similarities to the sphere than to the cylinder. Then, give ONA causal knowledge that if it grabs the cube, the hand will be holding the cube. Now, you should ask ONA if it can grab (and then hold) the other two objects, i.e. if the hand applies a grab operation to the sphere/cylinder whether the hand will be holding the sphere/cylinder.

Now, write your analysis by focusing on how different the two answers created by ONA are, and how the similarity between the objects affects ONA's reasoning and knowledge transfer.

(Bonus point) Try to play with the example (especially with the properties of objects) so that you find the circumstances where ONA fails to correctly generalize its knowledge.

2. Knowledge transfer via identical relations. Your second task is to write a set of narsese statements that reflects the analogy between the solar system and the Rutherford atom model (see the below figure).

First, implement all the relations of the Rutherford atom, MoreMassiveThan, Attracts, and RevolevesAround, between the electron and the nucleus. Note that the relation nucleus MoreMassiveThan electron leads to the relation nucleus Attracts electron, which itself leads to the relation electron RevolvesAround nucleus.

/var/www/cadia.ru.is/wiki/data/attic/public/t-720-atai/atai-22/engineering_assignment_2.1665188320.txt.gz · Last modified: 2024/04/29 13:32 (external edit)

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki