KbRetro module of the

English and Russian bilingual ghost.pl AI in Perl

Mens Latina in Latin -- MindForth for Robots


1. Diagram of the KbRetro Mind-Module


   /^^^^^^^^^\  KbRetro handles yes-or-no answers  /^^^^^^^^^\
  /   EYE     \  QUERY-IDEA      _________        /   EAR     \
 /             \   |A| | | |    / KbRetro \      /             \
|   _______     |  |N| | | |   /           \    |  Y            |
|  /old    \    |  |N| | | |  /   affirm    \   |   E           |
| / image   \   |  |A| | | |  | query-idea  |---|----S          |
| \ fetch   /   |  | | | | |  |             |   |               |
|  \_______/    | d| |N|h| |  |   attach    |   |  N            |
|               | o| |O|a| |  |   250=NOT   |---|---O           |
|  visual       | e| |T|v| |  |   flag      |   |               |
|               | s| | |e| |  |             |   |  M            |
|  memory       |  | | | | |  |   remove    |   |   A           |
|               |  | | | |c|  | associative |   |    Y          |
|  reactivation |  | | | |h|  |   tags      |   |     B         |
|               |  | | | |i|  |   from      |---|------E        |
|  channel      |  | | | |l|  |   query     |   |               |
|   _______     |  | | | |d|  |   idea      |---|-(no response) |
|  /old    \    |  |_|_|_|_|_  \___________/    |               |
| / image   \   | /   Psy    \                  |               |
| \ store   /---|-\ Concepts /                  |               |
|  \_______/    |  \________/                   |               |


2. Purpose of the KbRetro Mind-Module

The KbRetro module retroactively zaps the knowledge-base (KB) of the AI Mind where a silent inference must wait for confirmation or negation by a human user.


3. Function of the KbRetro Mind-Module

From its MindBoot() sequence, an open-source AI Mind may know a general fact such as, "Women have a child," which would serve as a premise for a logical inference about any particular woman. You could also teach the AI Mind any number of other general facts such as, "Boys play games" or "Birds have wings." Once the AI knows the general fact, at some future time you may input a specific fact such as "Anna is a woman" or "John is a boy", and the AI will not only make a silent inference but also use the AskUser mind-module to ask for confirmation or refutation of the inference.

Netizens may try it out with an English-thinking AI Mind by using Internet Explorer to input "anna is a woman". Then the AI may ask, "Does Anna have a child?" There are four possible answers anticipated by the AI software: Yes; No; maybe; or no answer at all. Then the KbRetro() module adjusts the knowledge base (KB) with the answer. If the answer is "Yes", the KbRetro() module sets a positive value on the tru(th) flag for the inference being confirmed as true.


4. Code of KbRetro() from ghost327.pl AI source code in Perl


sub KbRetro() {  # http://ai.neocities.org/KbRetro.html 
  if ($kbzap == 432 || $kbzap == 404) {  # 2018-06-26: if 432=YES or 404=NO...
    if ($kbzap == 404) {  # 2018-06-26: 404=NO; 
      my @k=split(',',$psy[$tkbn]);  # 2018-07-01: adjust noun of silent inference;
      $psy[$tkbn]="8,$k[1],1,$k[3],$k[4],$k[5],$k[6],"  # 2019-08-01: enhance $tru.
      . "$k[7],$k[8],$k[9],$k[10],$k[11],$k[12],$k[13],"
      . "$k[14],$k[15],$k[16],$k[17],$k[18],$k[19],$k[20]";  # 2019-08-01
      @k=split(',',$psy[$tkbv]);  # 2018-07-01: at time of KB-verb adjustment;
      $psy[$tkbv]="0,$quverb,1,32,$k[4],250,8,"  # 2019-08-01: jux=250 for "NO".
      . "$k[7],0,0,$qusub,$quobj,$k[12],$k[13],"
      . "$tkbo,$k[15],$k[16],$k[17],$k[18],$k[19],$k[20]";  # 2019-08-01
    }  # 2018-06-26: end of test for a no-answer.
    if ($kbzap == 432) { # 2018-06-26: 432=YES; 
      my @k=split(',',$psy[$tkbn]);  # 2018-07-01: adjust noun of silent inference;
      $psy[$tkbn]="8,$k[1],1,$k[3],$k[4],$k[5],$k[6]," # 2019-08-01: enhance $tru.
      . "$k[7],$k[8],$k[9],$k[10],$k[11],$k[12],$k[13],"
      ." $k[14],$k[15],$k[16],$k[17],$k[18],$k[19],$k[20]";  # 2019-08-01
      @k=split(',',$psy[$tkbv]);  # 2018-06-26: at time of KB-verb adjustment;
      $k[7] = 3;  # 2018-10-08: assume dba=3 third person...
      $psy[$tkbv]="0,$quverb,1,32,$k[4],$k[5],8,"
      . "$k[7],0,0,$qusub,$quobj,$k[12],$k[13],"
      . "$tkbo,$k[15],$k[16],$k[17],$k[18],$k[19],$k[20]";  # 2019-08-01
    }  # 2018-06-26: end of test for a yes-answer.
  } else {  # 2018-06-26: if neither yes nor no answer comes in...
    my @k=split(',',$psy[$tkbn]);  # 2018-06-26: remove pre and seq tags from noun; 
    $psy[$tkbn]="$k[0],$k[1],1,$k[3],$k[4],$k[5],$k[6],"
    . "$k[7],$k[8],$k[9],0,0,$k[12],$k[13],"
    . "0,$k[15],$k[16],$k[17],$k[18],$k[19],$k[20]";  # 2019-08-01: no pre, seq or tkb.
    @k=split(',',$psy[$tkbv]);  # 2018-06-26: remove pre and seq tags from verb; 
    $psy[$tkbv]="$k[0],$k[1],1,$k[3],$k[4],$k[5],$k[6],"
    . "$k[7],$k[8],$k[9],0,0,$k[12],$k[13],"
    . "0,$k[15],$k[16],$k[17],$k[18],$k[19],$k[20]";  # 2019-08-01: no pre, seq or tkb.
  }  # 2018-06-26: end of test for either yes or no.  
  $quobj = 0;  # 2018-06-26: reset for safety.
  $tkbn = 0;   # 2018-06-26: reset for safety; 
  $tkbv = 0;   # 2018-06-26: reset for safety; 
}  # 2019-08-01: KbRetro() returns to EnThink()


5. Variables

$kbzap -- ZAP the knowledge base -- is a variable that holds the oldpsi word "YES" or "NO" when the InFerence() module has caused the AskUser() module to seek confirmation or denial of a silent inference from a human user engaged in a conceptual conversation with the AI Mind. KbRetro() uses the YES-value kbzap to confirm an inference, or the NO-value of kbzap to negate an inference.

$quobj -- query object – holds onto the psi identifier of a word chosen by the InFerence() module to be the direct object of a query created by the AskUser() module.

$qusub -- query subject – is a transfer-vehicle of the subject-identifier from any module prompting a question into the specific module that will ask the question.

$quverb -- query verb – is set in the InFerence() module with the identifier of a verb concept serving as part of an InFerence being made about user input. Then the AskUser() module transforms the quverb identifier into the yes-or-no-verb identifier ynverb so that AskUser() can use the query-verb to ask a question expecting a yes-or-no answer.

$tkbn -- time-in-knowledge-base-noun -- is set in the InFerence() module as the concept-array time-point of the subject-noun in a yes-or-no question to be asked of the human user by AskUser() to confirm or negate an InFerence being made by the logical InFerence module.

$tkbo -- time-in-knowledge-base-object -- is set in the InFerence() module as the concept-array time-point of the direct-object-noun in a silent InFerence to be confirmed or negated retroactively by the KbRetro() module after a human user has responded to a question posed by the AskUser() module. May be similar to tdo in the EnParser() module, but tkbo is the last of three consecutive time-points in the silent InFerence created by the InFerence() module for automated reasoning.

$tkbv -- time-in-knowledge-base-verb -- is the time-point of a verb-concept in an AskUser() question for a human user to confirm or deny the truth of a logical InFerence made by the AI.

$tru -- tru(th) variable serving as a flag-panel tag to hold dynamically the believed reliability or truth-value of an idea. Since the truth-value is the first item in the conceptual flag-panel, a positive value in the first slot of the code above responding to a "YES" input represents the "tru" variable without actually naming the variable in the pertinent code.


6. Troubleshooting and Robotic Psychosurgery

6.1.a. Symptom: (Something goes wrong.)
6.1.b. Solution: (AI Mind Maintainer devises solution.)


7. Future Development


8. Resources

Please see

http://github.com/kernc/mindforth/blob/master/wiki/KbRetro.wiki

http://cyborg.blogspot.com/search/label/KbRetro -- is a special weblog URL which invites Netizens to view blog-posts discussing the KbRetro mind-module.

http://groups.google.com/group/comp.ai.nat-lang

http://groups.google.com/group/sci.logic


Wikipedia
* http://en.wikipedia.org/wiki/Modularity_of_Mind
* http://en.wikipedia.org/wiki/Language_module
* http://en.wikipedia.org/wiki/Double_negative
* http://en.wikipedia.org/wiki/Double_negative_elimination
* http://en.wikipedia.org/wiki/Negation
* http://en.wikipedia.org/wiki/Negation_normal_form
* http://en.wikipedia.org/wiki/Logic
* http://en.wikipedia.org/wiki/First-order_logic
* http://en.wikipedia.org/wiki/If_and_only_if
* http://en.wikipedia.org/wiki/Logical_conjunction
* http://en.wikipedia.org/wiki/Logical_disjunction
* http://en.wikipedia.org/wiki/Reasoning
* http://en.wikipedia.org/wiki/Automated_reasoning
* http://en.wikipedia.org/wiki/Syllogism
* http://en.wikipedia.org/wiki/Category:Computational_linguistics


9. AiTree of Ghost AI Mind-Modules


Return to top; or to
Tiananmen Square IV VI Doonesbury
javascript subreddit for AI Mind discussion;
Forth subreddit for MindForth discussion;
Perl subreddit for ghost.pl AI Mind Maintainers.
http://old.reddit.com/r/ControlProblem -- NOT SOLVED.
http://en.wikipedia.org/wiki/Natural_language_understanding -- solved.
Iskusstvenny Intellekt Programming Journal for Artificial Intelligence in Russian Language.
Converting ancient Latin AI into modern Russian AI
http://ai.neocities.org/Dushka.html -- tutorial Russian AI;
If you have any questions about the First Working AGI, please Join the Discussion.
Joint Artificial Intelligence Center (JAIC) -- the AI Manhattan Project.
Subject to change without notice.
Many thanks to NeoCities.
http://neocities.org/blog