Get Last Answer

<< Click to Display Table of Contents >>

Navigation:  3. Script Language > AI - Artificial Intelligence Commands > AIC. - Artificial Intelligence Command > AI - History >

Get Last Answer

AIC.Get Last Answer

Previous Top Next


MiniRobotLanguage (MRL)

 

AIC.Get Last Answer
Get the last used Answer.

 

clip0670

 

Get the last Answer that was sent from the AI.

 

Intention

 

The AIC.Get Last Answer command in the Smart-Package Robot (SPR) allows users recall the last Question that was send to any AI-Model.
This command can be used for any AI Model whether its Local or Online..

 

Syntax:

 

AIC.Get Last Answer|<Variable for Return>

 

Example Usage:

AIC.Get Last Answer|$$RET

MBX.$$RET

 

This example Recalls the last Prompt send to any AI-Model..

 

AIL.Set Number|1

AIL.Set Temperature|$$LR0

AIL.Set Model|Hermes

 

$$TXT=Hello! Please tell me what 5+6 is.

AIL.Ask GPT4All|$$TXT|$$REA

DBP.-------------

DBP.$$REA

DBP.-------------

AIC.gla|$$REB

DBP.The last Answer was:

DBP.$$REB

DBP.-------------

ENR.

 

 

Syntax

 

 

AIC.Get Last Answer[|P1]

AIC.GLA[|P1]

 

 

Parameter Explanation

 
P1 - opt. Variable for the result. If omitted TOS i used.

 

Example

 

'*****************************************************

' EXAMPLE 1: AIC.-Commands

'*****************************************************

VAN.$$TIM=#dtime#

AIL.SetModel|$$MOD

AIL.Set MaxToken|1024 

AIC.Set Number|1

FOR.$$LR0|0|1|0.1

  AIL.Set Temperature|$$LR0

  AIL.Set Model|Hermes

 

  $$TXT=Hello! I have a list of items represented as a string, and I would like your assistance in sorting these items alphabetically. The items in the list are separated by periods. Here is the list:

  $$TXT=$$TXT "ISP.NSP.WSP.GSP.SSP."

  $$TXT=$$TXT Please follow these steps to sort the items:

  $$TXT=$$TXT Split the string into individual items based on the period ('.') delimiter.

  $$TXT=$$TXT Sort the resulting array of items in alphabetical order.

  $$TXT=$$TXT Join the sorted items back into a single string, using the period ('.') as the delimiter.

  $$TXT=$$TXT Please provide me with the sorted string as the output. DO not generate Python code. Thank you!

 

  AIC.Estimate Token Count|$$TXT|$$TOA

  AIL.Ask GPT4All|$$TXT|$$REA

  CAL.$$TIU=#dsince#|i

  AIC.Estimate Token Count|$$REA|$$TOB

  DBP.-------------

  VAR.$$OUT=$$REA $crlf$Temp. $$LR0 $crlf$ Time used: $$TIU sec.$crlf$Tokens in Prompt: $$TOA$crlf$Tokens in Anwer: $$TOB

  DBP.$$OUT

  DBP.-------------

  AIC.gla|$$REB

  DBP.The last Amswer was:

  DBP.$$REB

NEX.

ENR.

 

 

Remarks

-

 

Limitations:

-

 

 

See also:

 

  Set_Key

  Ask_Chat

  Ask_Completion