Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

121
LINES

< > BotCompany Repo | #1002833 // A Thought Engine in JavaX

Document

Hello!

I am the real Stefan Reich (<< insider joke!).

I am making a thought engine in JavaX.


Simplified Natural Language
---------------------------

The engine will support natural language (English).

More precisely, it works with a *modified* version of English called SNL (Simplified Natural Language).

The point of SNL is to make structures explicit. It adds 4 special symbols (<, >, [, ]); the rest is more or less plain English.

If you ignore the extra symbols, you can read SNL like an English text.

SNL example: [i < am < tired]

The arrows are this way to indicate that "I" is the main word.

In SNL, everything must be lower case. Upper case indicates variables.

SNL example with variables: [i < am < X]

If you want to include special words or symbols, quote them.

Example:
  ["Nvidia" < is < a > company]

Oops, there is a right arrow now. Why is that? It indicates that "a" is a minor word that is bound to the major word "company".

Note that the right arrow binds stronger than the left arrow, so the above example is equivalent to this:

  ["Nvidia" < is < [a > company]]

If you get the arrows wrong: Don't worry. The point of making an Artificial Intelligence is that it does these things for us.

In the end, we only want to write English and have the system make SNL automatically.

It's not that hard either. In most cases, the left arrow is perfect. After an "a" or "the", there is usually a right arrow. Same after an adjective when followed by a noun.

The advantages of the arrows is that sentences can be simplified automatically by removing the minor parts.

Example: [i < love < ducks < that < swim < at < night]

This simplifies to, for example: [i < love < ducks]

Or to: [i < love < ducks < that < swim]


Theories
--------

Theories are collections of statements and rules.

A statement is something like [i < am < a > computer]

A rule is something like [if < [i < am < tired] < then < [i < should < go < to < bed]]


Solving
-------

Solving is asking a question and having the system try to answer it (using any number of theories).

Example:
  Question: [i < am < X]
  Theory:   [i < am < tired]
  Answer:   X = tired

There might be multiple answers which can be queried one by one.

Solving is already implemented (see #1002830).


Rewriting
---------

Rewriting is taking a theory and deriving new statements from it automatically.

Example:
  Theory: 
    [
      if   [X < is < a > Y]
      and  [a > Y < has < a > Z]
      then [X < has < a > Z]
    ]
    [ mark < is < a > guy ]
    [ a > guy < has < a > gun ]

  Derived statement:
    [ mark < has < a > gun ]

Rewriting is already implemented (see #1002832).


Native code
-----------

For including native code, we rely on Java and provide simple bindings like this:

SNL:  X = quote(Y)
Java: static S quote(S y) { ... }

For constructing or deconstructing complex terms, there is a very simple tree-like Java class called "Lisp".


Meta-solving
------------

The most important idea is to have the system reason about itself and about theories. To this end, solves and rewrites can be triggered from within SNL and the results can be stored as insights about theories and logic engines.


General direction
-----------------

We should express all ideas as naturally as possible. Just write down the English sentence that is in your mind when thinking about things and put it into a new theory.

If the system can't understand your sentence, we will make a translator for it. We have experience... for example, we've been making lots of translators to convert JavaX (extended/simplified Java) into regular Java.

download  show line numbers   

Travelled to 12 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1002833
Snippet name: A Thought Engine in JavaX
Eternal ID of this version: #1002833/1
Text MD5: c0f8d2e9a4264724a3096de282d947a5
Author: stefan
Category:
Type: Document
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2016-03-02 03:35:41
Source code size: 3739 bytes / 121 lines
Pitched / IR pitched: No / No
Views / Downloads: 683 / 127
Referenced in: [show references]