Asked — Edited

Snybot Plugin Question

I tried loading the SynBot plugin following the tutorial and the plugin just comes up as a white box. I tried loading it into a clean new project and got the same results. I am using window 10 32bit laptop, ARC version 2018.01.15.00

My guess is the plugin needs to be updated.

any suggestions?


ARC Pro

Upgrade to ARC Pro

Unleash your creativity with the power of easy robot programming using Synthiam ARC Pro

PRO
Synthiam
#1  

Did you check the instructions on how to use the plugin? I think it depends on some program. You can ask the author here: https://synthiam.com/Community/Questions/10001

PRO
USA
#2  

Yup, I followed the tutorial step by step. Thank you for the advice, I will do that.

#3  

Hi

I am author of the plugin I will update it in some days due to synbot framework updates and new features in progress

I just need some tests and tutorial updating

hope you can test it deep in some days

PRO
USA
#4  

I would gladly do some testing for you. I am sure there are others who would help with the testing also. Just post when the new version is ready for testing.

#5  

Hi

New version of Synbot plugin is on line with tutorial updated and Example JD Synbot on EZ Cloud.

Don't hesitate if you have questions or problems ..... Version 2 with some new learning capabilities will be ready in 3 to 4 weeks.

Jean Luc

PRO
USA
#6  

Jean Luc, Can the SIML project be ether a classic or modern or does it have to be a classic? Thank you Richard

PRO
USA
#7  

@ Jean Luc I can not get the bot to respond correctly.

This is the Syn Bot Window Do not forget to Save Context when you decide to stop the chat with the bot Otherwise all new bot learnings will be lost Bot initialized for user id Jean luc : welcome to synbot Maya : hi i'm maya i'm an humanoid robot but how do you want i call you : richard Maya : what a wonderful name i will call you richard richard : how are you Maya : i can't answer

Must be a configuration issue but I can not figure it out.

I have saved the SIML project to C:/users/richard/UNAS/SynBot. So that folder has the UNAS.simlproj file and a directory named UNAS IN that directory is the Settings folder and the Templates folder. This is also where I copied your SIML files and is the folder I set in both of the directory settings on the config page of the plugin.

#8  

Hi

I think i have not included in the example files the how are you pattern so it is normal and bot réponse when it dont Know the input pattern is set to i can't answer Bot can only respond to user inputs if the corresponding pattern is included in the siml files the same Way all aiml software You can include this new pattern in siml files I Will send you to morrow example in order to react to the how are you input

Look at the test unit files included with the plugin and at the tutorial to discover more

Happy you test the plugin ....

#9  

And for first question only Classic to day i just look to the opportunity to migrate to oscova modern version

PRO
USA
#10  

Jlucben, Here is a routine I came up with. It watches for change in the $SynbotTextResponse variable and then checks if the Learned.siml file exists (UnasLearned.siml) in mycase and then takes the learned data from that file and writes it to another file NewData.siml. This way the learned siml data is not lost at restart. I have created a few simple siml files for. BlankCanBlank, BlankHaveBlank, BlankCanNotBlank... Here is the code for one of the siml file BlankCanBlank


<Siml xmlns:x="http://syn.co.in/2014/siml#external" xmlns:Think="http://syn.co.in/2014/siml#think">
  <Concept Name="BlankCanBlank" Type="Public">
     <Model>
      <Pattern>* can *</Pattern>
      <Response>
         <Learn>
          <Model>
            <Pattern>Can <Process xml:space="preserve"><Match /> <Match 
               Index="2" /></Process></Pattern>
            <Response>Yes, <Process><Match Index="1" /> can <Match Index="2" />
           </Process></Response>
          </Model>
	   </Learn>         
         Ok, I now know that <Match /> can <Match Index="2" /></Response>
    </Model>
 </Concept>
</Siml>

And here is the Learned file data I capture and copy to the NewData file


<Model>
      <Pattern>Can ducks swim</Pattern>
      <Response>Yes, ducks can swim</Response>
    </Model>
    <Model>
      <Pattern>Can dogs swim</Pattern>
      <Response>Yes, dogs can swim</Response>
    </Model>
    <Model>
      <Pattern>Can birds fly</Pattern>
      <Response>Yes, birds can fly</Response>
    </Model>
    <Model>
      <Pattern>Can birds sing</Pattern>
      <Response>Yes, birds can sing</Response>
    </Model>

So the pattern and the response is created by the <learn>

Here is the EZ-Script that does the copy and then deletes the Learned file.


:LearnedData
WaitForChange($SynbotTextResponse)

DefineArray($SourceArray,1)
DefineArray($DestArray,1)
$SourceFile = &quot;c:/users/richard/unas/synbot/UnasLearned.siml&quot;
$DestFile = &quot;c:/users/richard/unas/synbot/unas/NewData.siml&quot;
FileReadReset($SourceFile)
FileReadReset($DestFile)
if(fileExists($SourceFile) = true)
  :FileLoop
  if(FileReadEnd($SourceFile) = false)
    AppendArray($SourceArray,FileReadLine($SourceFile))
    Goto(FileLoop)
  endif
  #Filter out the rainbows and buttercups
  if(Contains($SourceArray[5], &quot;XXXXX&quot;))
  FileReadReset($SourceFile)
   goto(End)
 endif
  :FileLoop2
  if(FileReadEnd($DestFile) = false)
    AppendArray($DestArray, FileReadLine($DestFile))
    Goto(FileLoop2)
  endif
  $DArrayLength = GetArraySize(&quot;$DestArray&quot;)
  $SArrayLength = GetArraySize(&quot;$SourceArray&quot;)
  $DestArray[$DArrayLength - 2] = $SourceArray[4]
  $DestArray[$DArrayLength - 1] = $SourceArray[5]
 # $DestArray[$DArrayLength - 1] = $SourceArray[6]
  AppendArray($DestArray, $SourceArray[6])
  AppendArray($DestArray, $SourceArray[7])
  AppendArray($DestArray, $SourceArray[8])
  AppendArray($DestArray, $SourceArray[9])
  $DestArray[2] = &quot;&lt;Concept Name=&quot; + GetAsByte(34) + &quot;NewData&quot; + GetAsByte(34) + &quot; Type=&quot; + GetAsByte(34) + &quot;Public&quot; + GetAsByte(34) + &quot; repeat=&quot; + GetAsByte(34) + &quot;true&quot; + GetAsByte(34) + &quot;&gt;&quot;
 if($SArrayLength &gt; 10)
  AppendArray($DestArray, $SourceArray[10])
  AppendArray($DestArray, $SourceArray[11])
  AppendArray($DestArray, $SourceArray[12])
  AppendArray($DestArray, $SourceArray[13])
 endif
  FileReadReset($SourceFile)
 FileReadReset($DestFile)
 
  FileDelete($SourceFile)
  FileDelete($DestFile)
  
  $DArrayLength = GetArraySize(&quot;$DestArray&quot;)
  $Counter = 1
  :DestLoop
  repeatwhile($Counter &lt; $DArrayLength)
  FileWriteLine($DestFile, $DestArray[$Counter])
  $Counter = $Counter + 1
  Goto(DestLoop)
  endrepeatwhile
  endif
  :End
  $SayWhat = $SynbotTextResponse
  goto(LearnedData)

PRO
USA
#11  

Rewrite of the EZ-Script This now allows for any size Learned.siml source file. I needed the rewrite so as to support having random and multiple responses learned.

Here is an example of a multiple response learn That creates: Where is * located And Is * located in *


&lt;Siml xmlns:x=&quot;http://syn.co.in/2014/siml#external&quot; xmlns:Think=&quot;http://syn.co.in/2014/siml#think&quot;&gt;
  &lt;Concept Name=&quot;BlankIsLocatedInBlank&quot; Type=&quot;Public&quot;&gt;
     &lt;Model&gt;
      &lt;Pattern&gt;* is located in *&lt;/Pattern&gt;
      &lt;Response&gt;
         &lt;Learn&gt;
          &lt;Model&gt;
            &lt;Pattern&gt;Where is &lt;Process xml:space=&quot;preserve&quot;&gt;&lt;Match /&gt; located &lt;/Process&gt;&lt;/Pattern&gt;
            &lt;Response&gt;&lt;Process&gt;&lt;Match Index=&quot;1&quot; /&gt; is located in &lt;Match Index=&quot;2&quot; /&gt;&lt;/Process&gt;&lt;/Response&gt;
          &lt;/Model&gt;
		&lt;Model&gt;
            &lt;Pattern&gt;is &lt;Process xml:space=&quot;preserve&quot;&gt;&lt;Match /&gt; located in &lt;Match Index=&quot;2&quot; /&gt;&lt;/Process&gt;&lt;/Pattern&gt;
            &lt;Response&gt;&lt;Process&gt;Yes, &lt;Match Index=&quot;1&quot; /&gt; is located in &lt;Match Index=&quot;2&quot; /&gt;&lt;/Process&gt;&lt;/Response&gt;
          &lt;/Model&gt;
          &lt;/Learn&gt;         
         Ok, I now know that &lt;Match /&gt; is located in &lt;Match Index=&quot;2&quot; /&gt;&lt;/Response&gt;
    &lt;/Model&gt;
  &lt;/Concept&gt;
&lt;/Siml&gt;

And the Random looks like this:


Siml xmlns:x=&quot;http://syn.co.in/2014/siml#external&quot; xmlns:Think=&quot;http://syn.co.in/2014/siml#think&quot;&gt;
  &lt;Concept Name=&quot;BlankCanBlank&quot; Type=&quot;Public&quot;&gt;
     &lt;Model&gt;
      &lt;Pattern&gt;* can *&lt;/Pattern&gt;
      &lt;Response&gt;
         &lt;Learn&gt;
          &lt;Model&gt;
            &lt;Pattern&gt;Can &lt;Process xml:space=&quot;preserve&quot;&gt;&lt;Match /&gt; &lt;Match Index=&quot;2&quot; /&gt;&lt;/Process&gt;&lt;/Pattern&gt;
            &lt;Response&gt;&lt;Random&gt;
			&lt;Item&gt;Yes, &lt;Process&gt;&lt;Match Index=&quot;1&quot; /&gt; can &lt;Match Index=&quot;2&quot; /&gt;&lt;/Process&gt;&lt;/Item&gt;
			&lt;Item&gt;That is correct, &lt;Process&gt;&lt;Match Index=&quot;1&quot; /&gt; can &lt;Match Index=&quot;2&quot; /&gt;&lt;/Process&gt;&lt;/Item&gt;
			&lt;Item&gt;You got it, &lt;Process&gt;&lt;Match Index=&quot;1&quot; /&gt; can &lt;Match Index=&quot;2&quot; /&gt;&lt;/Process&gt;&lt;/Item&gt;
			&lt;Item&gt;With out a dought, &lt;Process&gt;&lt;Match Index=&quot;1&quot; /&gt; can &lt;Match Index=&quot;2&quot; /&gt;&lt;/Process&gt;&lt;/Item&gt;
			&lt;Item&gt;For sure, &lt;Process&gt;&lt;Match Index=&quot;1&quot; /&gt; can &lt;Match Index=&quot;2&quot; /&gt;&lt;/Process&gt;&lt;/Item&gt;
			&lt;/Random&gt;
&lt;/Response&gt;
          &lt;/Model&gt;
	   &lt;/Learn&gt;         
         Ok, I now know that &lt;Match /&gt; can &lt;Match Index=&quot;2&quot; /&gt;&lt;/Response&gt;
    &lt;/Model&gt;
      &lt;/Concept&gt;
&lt;/Siml&gt;

Here is the updated EZ-Script.


:LearnedData1
#WaitForChange($SynbotTextResponse)
DefineArray($SourceArray,1)
DefineArray($DestArray,1)
$SourceFile = &quot;c:/users/richard/unas/synbot/UnasLearned.siml&quot;
$DestFile = &quot;c:/users/richard/unas/synbot/unas/NewData.siml&quot;
FileReadReset($SourceFile)
FileReadReset($DestFile)
if(fileExists($SourceFile) = true)
:ReadSource
 if(FileReadEnd($SourceFile) = false)
   $SourceData = FileReadLine($SourceFile)
   if(Contains($SourceData, &quot;XXXXX&quot;))
   FileReadClose($SourceFile)
     goto(TheEnd)
   endif
    AppendArray($SourceArray,$SourceData)
    Goto(ReadSource)
    FileReadReset($SourceFile)
  endif
  :ReadDestination
  if(FileReadEnd($DestFile) = false)
    AppendArray($DestArray, FileReadLine($DestFile))
    Goto(ReadDestination)
  endif
  $DArrayLength = GetArraySize(&quot;$DestArray&quot;)
  $SArrayLength = GetArraySize(&quot;$SourceArray&quot;)
  $DestArray[$DArrayLength - 2] = $SourceArray[4]
  $DestArray[$DArrayLength - 1] = $SourceArray[5]
  $LineCount = 6
  repeatwhile($LineCount &lt; $SArrayLength)
  AppendArray($DestArray, $SourceArray[$LineCount])
  $LineCount = $LineCount + 1
  endrepeatwhile
  $DestArray[2] = &quot;&lt;Concept Name=&quot; + GetAsByte(34) + &quot;NewData&quot; + GetAsByte(34) + &quot; Type=&quot; + GetAsByte(34) + &quot;Public&quot; + GetAsByte(34) + &quot; repeat=&quot; + GetAsByte(34) + &quot;true&quot; + GetAsByte(34) + &quot;&gt;&quot;
    
  FileReadclose($SourceFile)
  FileReadClose($DestFile)
  FileDelete($SourceFile)
  FileDelete($DestFile)
  
  $DArrayLength = GetArraySize(&quot;$DestArray&quot;)
  $Counter = 1
  :DestLoop
  repeatwhile($Counter &lt; $DArrayLength)
  FileWriteLine($DestFile, $DestArray[$Counter])
  $Counter = $Counter + 1
  Goto(DestLoop)
  endrepeatwhile
endif
:TheEnd
  $SayWhat = $SynbotTextResponse
  goto(LearnedData1)
Halt()

It works slick.

#12  

Hi

I will correct the plugin in order to append the learned models in the learned.siml file, when a new model is learned.

But your code is working fine ......

PRO
USA
#13  

I still have a lot to learn about SIML, but I love the plugin. Great job. I will let you know of anything else I find before I write code to work around it.

#14  

Thanks

I have a developper licence for Synbot and have easiercontacts with the indian company. So don't hesitate to contact me in case of problems or questions before coding.

I will publish a new version as soon as possible with ability to integrate easilly personnal Adaptators for new SIML tags Coded in C# and a Bot learning framework using User Variables and Maps.

New version with update Learn.SIML in Append mode will be soon.

PRO
USA
#15  

Syntax for the exponent function

I tried <Match />e<Match Index ="2" />

where both match = 2 and I get an answer of 200

If I try <Match />e(<Match Index ="2" />) I get nothing

PRO
USA
#16  

couldn't find anything on it so I used JavaScript:


&lt;Model&gt;
		&lt;Pattern&gt;what is * to the power of *&lt;/Pattern&gt;
		&lt;Response&gt;The answer is &lt;Js&gt;function powr(num1, num2){
		return Math.pow(num1, num2);
		}
		powr(&lt;Match /&gt;, &lt;Match Index=&quot;2&quot; /&gt;);
		&lt;/Js&gt;
		&lt;/Response&gt;
&lt;/Model&gt;

#17  

Correct syntax here

[Model]
		[Pattern]what is * to the power of *[/Pattern]
		[Response]The answer is [Math][Match /]e[Match At=&quot;2&quot;/][/Math]
		[/Response]
     [/Model]

But not working , I will post a report. Your JS Script is the good solution.

Plugin has been updated for Use of Learn SIML Tag- you can have look to the Tutorial I have updated Step 7 Ter. Now it is working fine ....

#18  

Hi

I have a look to your SIML code for BlankCanBlank and BlankIsLocatedinBlank

And have try to improve and optimize RestructuredLearn.zip

Comments are in the Code. Main improvement is the ability to use in Input Text The Pattern Reductions of the example I published.

Hi maya I would like to know if ducks can swim , can you tell me if ducks swim , .... will be working , ....

You need to upgrade plugin version to V4 as I use a specific SIMl adapter Textop

PRO
USA
#19  

This is awesome, thank you much. It is going to take me awhile to get my head around how this one works. Great work. I have a spreadsheet I would like to send you. It is my brain spreadsheet my email is rz90208@gmail.com I also have an excel spreadsheet of the top 100 pop music form from 1890 to 2013 that I would like to incorporate into the robot brain.

#20  

You can send me your brain spreadsheects to jeanlucben@gmail.com

I will have a look

Don’t hesitate if you have questions or difficulties

PRO
USA
#21  

JeanLuc, The new Reconstructed Learn works fine except that the code it generates crashes ARC. So if I tell the bot that Dogs have teeth, the bot responds with OK I now know that dogs have teeth. and adds this code to the Learned.siml file.


&lt;Model&gt;
      &lt;Pattern&gt;
        &lt;Item&gt;Do dogs have teeth&lt;/Item&gt;
        &lt;Item&gt;XXXXXFROMPATTERNREDUCTION1 Do dogs have teeth&lt;/Item&gt;
      &lt;/Pattern&gt;
      &lt;Response xml:space=&quot;preserve&quot;&gt;
&lt;Think&gt;
   	 &lt;If Var=&quot;Typego&quot; Value=&quot;&quot;&gt;
   	 &lt;Goto xml:space=&quot;preserve&quot;&gt;XXXXXPROCESSRESPONSE_BLANKHAVEBLANKdogs|teeth&lt;/Goto&gt;
	 &lt;/If&gt;	 
&lt;/Think&gt;          
&lt;/Response&gt;
    &lt;/Model&gt;
    &lt;Model&gt;
      &lt;Pattern&gt;
        &lt;Item&gt;XXXXXFROMPATTERNREDUCTION1 IF dogs have teeth&lt;/Item&gt;
      &lt;/Pattern&gt;
      &lt;Response xml:space=&quot;preserve&quot;&gt;
&lt;Think&gt;
  	 &lt;If Var=&quot;Typego8&quot; Value=&quot;1&quot;&gt;
		 &lt;Goto xml:space=&quot;preserve&quot;&gt;XXXXXPROCESSRESPONSE_BLANKHAVEBLANKdogs|teeth&lt;/Goto&gt;
	 &lt;/If&gt;		 
 &lt;/Think&gt;          
&lt;/Response&gt;
    &lt;/Model&gt;

but if I now ask the bot if dogs have teeth, it seems SynBot looks up and crashes ARC.

#22  

Hi

It is working on my version

User-inserted image

Do you have updated the plugin to the new version v5 and reload SIML example files in new version SaveV5Published.zip

and do you have suppress your old version of Learned.siml

PRO
USA
#23  

Just to be sure, I deleted all siml files. Reinstalled V5 and unzipped SaveV5Published into my project folder. and tried using Located in NOT have Stevens Point is located in Wisconsin and when I ask the bot where is Stevens Point located, is freezes and crashes ARC. I will try it in a clean ARC project and let you know

#24  

I will try to reinstall on another pc to morrow and let you know what is happening

#25  

I just test on another PC

I publish a V6 without change It seems that V5 was not correctly uploaded as some of the DLL was older one and the version release was not correct

After updating the plugin, you can verify in folder C:\Users\Public\Documents\EZ-Builder\Plugins(GUID) where GUID is the plugin GUID (The last modified) the plugin.xml file

it must be in version release 6

&lt;?xml version=&quot;1.0&quot;?&gt;

-&lt;PluginV1XML xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot; xmlns:xsd=&quot;http://www.w3.org/2001/XMLSchema&quot;&gt;

&lt;FRIENDLY_NAME&gt;Synbot Plugin&lt;/FRIENDLY_NAME&gt;

&lt;DLL_FILENAME&gt;SynbotPlugin.dll&lt;/DLL_FILENAME&gt;

&lt;AUTHOR_NAME&gt;Jlucben&lt;/AUTHOR_NAME&gt;

&lt;LICENSE_URL&gt;https://synthiam.com/tutorials/plugin-license.aspx&lt;/LICENSE_URL&gt;

&lt;PLUGIN_GUID&gt;eae7154f-c1e0-4e41-a661-bc4d7fc66e90&lt;/PLUGIN_GUID&gt;

&lt;CATEGORY_TYPE&gt;Artificial Intelligence&lt;/CATEGORY_TYPE&gt;

&lt;DESCRIPTION&gt;Plugin interfacing with the SynBot Bot Solution&lt;/DESCRIPTION&gt;

&lt;VersionRelease&gt;6&lt;/VersionRelease&gt;

&lt;/PluginV1XML&gt;
Germany
#26  

Hi jeanlucben, Today I have installed your plugin and it works very well. With SynBot Studio I will now try to make extensions for the German language. You did a fantastic job! Thanks a lot for this ! I hope you continue your development at this plugin and we can look forward to new versions.

#27  

Thanks joki

After some travels , I am beginning to work on a new version. If you find bugs in the current version , I will be pleased to fix them. I think some are remaining ......

Jean-Luc