15-10-2025 16:05:10.47879[0][4] - Elapsed time: 9.838 milliseconds
[conversation_start.php][Called outside of function][56]
Conversation starting. Current system specs:
  Program O version:            2.6.11
  Server Software:              LiteSpeed
  PHP Version:                  7.4.33
  OS:                           Linux
  OS Version:                   #1 SMP PREEMPT_DYNAMIC Thu Sep 4 05:08:52 EDT 2025
  MySQL Version:                11.4.8-MariaDB-cll-lve
  Multi-byte functions enabled: true 
-----------------------
15-10-2025 16:05:10.47937[4][4] - Elapsed time: 0.582 milliseconds
[load_aimlfunctions.php][Called outside of function][16]
AIML function include files loaded 
-----------------------
15-10-2025 16:05:10.47976[4][4] - Elapsed time: 0.391 milliseconds
[load_convofunctions.php][Called outside of function][16]
Convofunction include files loaded 
-----------------------
15-10-2025 16:05:10.47999[4][4] - Elapsed time: 0.230 milliseconds
[load_userfunctions.php][Called outside of function][14]
userfunctions include files loaded 
-----------------------
15-10-2025 16:05:10.48075[4][4] - Elapsed time: 0.757 milliseconds
[load_addons.php][Called outside of function][19]
Loading addons 
-----------------------
15-10-2025 16:05:10.48077[4][4] - Elapsed time: 0.023 milliseconds
[conversation_start.php][Called outside of function][69]
Loaded all Includes 
-----------------------
15-10-2025 16:05:10.48102[1][4] - Elapsed time: 0.248 milliseconds
[conversation_start.php][Called outside of function][118]
PHP ERROR [Warning] -session_id(): Cannot change session id when session is active in /home/si2h6234/public_html/david.si2024.com/Program-O/chatbot/conversation_start.php on Line 118 
-----------------------
15-10-2025 16:05:10.48149[0][4] - Elapsed time: 0.477 milliseconds
[conversation_start.php][Called outside of function][122]
Debug level: 4
session ID = 1fee6cd431aa553591e8ea4fe3b70911 
-----------------------
15-10-2025 16:05:10.48151[4][4] - Elapsed time: 0.022 milliseconds
[conversation_start.php][Called outside of function][125]
Conversation continuing. User said 'hei loqbot'. 
-----------------------
15-10-2025 16:05:10.48156[4][4] - Elapsed time: 0.043 milliseconds
[intialise_conversation.php][read_from_session][155]
Reading from session 
-----------------------
15-10-2025 16:05:10.48157[4][4] - Elapsed time: 0.015 milliseconds
[intialise_conversation.php][load_default_bot_values][110]
Loading db bot personality properties 
-----------------------
15-10-2025 16:05:10.48159[3][4] - Elapsed time: 0.019 milliseconds
[intialise_conversation.php][load_default_bot_values][118]
load db bot personality values SQL: SELECT * FROM `si2h6234_dbdavid`.`botpersonality` WHERE `bot_id` = 1; 
-----------------------
15-10-2025 16:05:10.48208[4][4] - Elapsed time: 0.492 milliseconds
[intialise_conversation.php][check_set_convo_id][643]
Obtaining the convo id from form vars. Value: 65491f288a916512f50b688f84df9028 
-----------------------
15-10-2025 16:05:10.48212[2][4] - Elapsed time: 0.037 milliseconds
[intialise_conversation.php][check_set_bot][581]
Checking and/or setting the current bot. 
-----------------------
15-10-2025 16:05:10.48214[3][4] - Elapsed time: 0.021 milliseconds
[intialise_conversation.php][check_set_bot][599]
Making sure the bot exists. SQL = SELECT * FROM `si2h6234_dbdavid`.`bots` WHERE bot_id = 1 AND `bot_active` = 1; 
-----------------------
15-10-2025 16:05:10.48269[2][4] - Elapsed time: 0.552 milliseconds
[intialise_conversation.php][check_set_bot][616]
BOT ID: 1 
-----------------------
15-10-2025 16:05:10.48273[2][4] - Elapsed time: 0.034 milliseconds
[intialise_conversation.php][check_set_user][672]
Checking and setting the user info, as needed. 
-----------------------
15-10-2025 16:05:10.48321[3][4] - Elapsed time: 0.480 milliseconds
[intialise_conversation.php][check_set_user][705]
Loading client properties from the DB - sql:
SELECT `name`, `value` FROM `si2h6234_dbdavid`.`client_properties` WHERE `user_id` = 7 AND `bot_id` = 1; 
-----------------------
15-10-2025 16:05:10.48373[2][4] - Elapsed time: 0.519 milliseconds
[spell_checker.php][run_spell_checker_say][36]
Starting function and setting timestamp. 
-----------------------
15-10-2025 16:05:10.48389[2][4] - Elapsed time: 0.163 milliseconds
[spell_checker.php][spell_check][60]
Preforming a spel chek on hei. 
-----------------------
15-10-2025 16:05:10.48392[2][4] - Elapsed time: 0.027 milliseconds
[spell_checker.php][load_spelling_list][117]
Loading the spellcheck list from the DB. 
-----------------------
15-10-2025 16:05:10.48466[2][4] - Elapsed time: 0.745 milliseconds
[spell_checker.php][spell_check][60]
Preforming a spel chek on  . 
-----------------------
15-10-2025 16:05:10.48471[2][4] - Elapsed time: 0.047 milliseconds
[spell_checker.php][spell_check][60]
Preforming a spel chek on loqbot. 
-----------------------
15-10-2025 16:05:10.48475[4][4] - Elapsed time: 0.039 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'hei loqbot' 
-----------------------
15-10-2025 16:05:10.48502[4][4] - Elapsed time: 0.277 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'HEI LOQBOT' 
-----------------------
15-10-2025 16:05:10.48505[2][4] - Elapsed time: 0.022 milliseconds
[conversation_start.php][Called outside of function][200]
Details:
User say: HEI LOQBOT
Convo id: 1fee6cd431aa553591e8ea4fe3b70911
Bot id: 1
Format: json 
-----------------------
15-10-2025 16:05:10.48506[4][4] - Elapsed time: 0.017 milliseconds
[intialise_conversation.php][check_set_format][752]
Using format: json 
-----------------------
15-10-2025 16:05:10.48508[2][4] - Elapsed time: 0.014 milliseconds
[intialise_conversation.php][load_that][769]
Loading the THAT array. 
-----------------------
15-10-2025 16:05:10.48510[3][4] - Elapsed time: 0.020 milliseconds
[intialise_conversation.php][load_that][784]
Getting conversation log entries for the current user. SQL:
SELECT `input`, `response` FROM `si2h6234_dbdavid`.`conversation_log` WHERE `user_id` = 7 AND `bot_id` = 1 ORDER BY `id` DESC limit 10; 
-----------------------
15-10-2025 16:05:10.48563[1][4] - Elapsed time: 0.533 milliseconds
[intialise_conversation.php][load_that][804]
Inputs returned:Array
(
    [0] => hai
    [1] => hai
)
 
-----------------------
15-10-2025 16:05:10.48566[4][4] - Elapsed time: 0.031 milliseconds
[intialise_conversation.php][load_that][805]
Loading previous responses into the ~THAT~ array. 
-----------------------
15-10-2025 16:05:10.48568[1][4] - Elapsed time: 0.015 milliseconds
[intialise_conversation.php][load_that][806]
Responses returned:Array
(
    [0] => Aduh, aku bingung nih. Bisa kasih tau maksud kamu dengan kata yang lain?
    [1] => Maaf, aku belum paham maksud kamu. Bisa diulang dengan cara lain?
)
 
-----------------------
15-10-2025 16:05:10.48570[2][4] - Elapsed time: 0.028 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.48572[2][4] - Elapsed time: 0.015 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => Maaf
    [1] =>  aku belum paham maksud kamu
    [2] =>  Bisa diulang dengan cara lain
    [3] => 
)

 
-----------------------
15-10-2025 16:05:10.48574[4][4] - Elapsed time: 0.025 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.48576[4][4] - Elapsed time: 0.018 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning 'Maaf aku belum paham maksud kamu Bisa diulang dengan cara lain ' 
-----------------------
15-10-2025 16:05:10.48578[4][4] - Elapsed time: 0.014 milliseconds
[parse_aiml.php][clean_that][251]
Cleaning up the ~THAT~ tag: 'Maaf aku belum paham maksud kamu Bisa diulang dengan cara lain ' 
-----------------------
15-10-2025 16:05:10.48579[4][4] - Elapsed time: 0.013 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'Maaf aku belum paham maksud kamu Bisa diulang dengan cara lain ' 
-----------------------
15-10-2025 16:05:10.48582[4][4] - Elapsed time: 0.026 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'MAAF AKU BELUM PAHAM MAKSUD KAMU BISA DIULANG DENGAN CARA LAIN' 
-----------------------
15-10-2025 16:05:10.48583[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml.php][clean_that][258]
Cleaning Complete. output = 'MAAF AKU BELUM PAHAM MAKSUD KAMU BISA DIULANG DENGAN CARA LAIN' 
-----------------------
15-10-2025 16:05:10.48584[2][4] - Elapsed time: 0.012 milliseconds
[intialise_conversation.php][push_on_front_convoArr][226]
Pushing 'MAAF AKU BELUM PAHAM MAKSUD KAMU BISA DIULANG DENGAN CARA LAIN' to the front of the [that] array 
-----------------------
15-10-2025 16:05:10.48590[4][4] - Elapsed time: 0.065 milliseconds
[intialise_conversation.php][load_blank_array_element][62]
Loading blank that array 
-----------------------
15-10-2025 16:05:10.48605[4][4] - Elapsed time: 0.143 milliseconds
[parse_aiml.php][clean_that][251]
Cleaning up the ~THAT~ tag: 'MAAF AKU BELUM PAHAM MAKSUD KAMU BISA DIULANG DENGAN CARA LAIN' 
-----------------------
15-10-2025 16:05:10.48607[4][4] - Elapsed time: 0.018 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'MAAF AKU BELUM PAHAM MAKSUD KAMU BISA DIULANG DENGAN CARA LAIN' 
-----------------------
15-10-2025 16:05:10.48609[4][4] - Elapsed time: 0.021 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'MAAF AKU BELUM PAHAM MAKSUD KAMU BISA DIULANG DENGAN CARA LAIN' 
-----------------------
15-10-2025 16:05:10.48610[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][clean_that][258]
Cleaning Complete. output = 'MAAF AKU BELUM PAHAM MAKSUD KAMU BISA DIULANG DENGAN CARA LAIN' 
-----------------------
15-10-2025 16:05:10.48612[2][4] - Elapsed time: 0.022 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.48613[2][4] - Elapsed time: 0.013 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => Aduh
    [1] =>  aku bingung nih
    [2] =>  Bisa kasih tau maksud kamu dengan kata yang lain
    [3] => 
)

 
-----------------------
15-10-2025 16:05:10.48614[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.48616[4][4] - Elapsed time: 0.014 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning 'Aduh aku bingung nih Bisa kasih tau maksud kamu dengan kata yang lain ' 
-----------------------
15-10-2025 16:05:10.48617[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml.php][clean_that][251]
Cleaning up the ~THAT~ tag: 'Aduh aku bingung nih Bisa kasih tau maksud kamu dengan kata yang lain ' 
-----------------------
15-10-2025 16:05:10.48618[4][4] - Elapsed time: 0.011 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'Aduh aku bingung nih Bisa kasih tau maksud kamu dengan kata yang lain ' 
-----------------------
15-10-2025 16:05:10.48620[4][4] - Elapsed time: 0.019 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN' 
-----------------------
15-10-2025 16:05:10.48621[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][clean_that][258]
Cleaning Complete. output = 'ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN' 
-----------------------
15-10-2025 16:05:10.48622[2][4] - Elapsed time: 0.011 milliseconds
[intialise_conversation.php][push_on_front_convoArr][226]
Pushing 'ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN' to the front of the [that] array 
-----------------------
15-10-2025 16:05:10.48624[4][4] - Elapsed time: 0.021 milliseconds
[parse_aiml.php][clean_that][251]
Cleaning up the ~THAT~ tag: 'ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN' 
-----------------------
15-10-2025 16:05:10.48625[4][4] - Elapsed time: 0.011 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN' 
-----------------------
15-10-2025 16:05:10.48627[4][4] - Elapsed time: 0.017 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN' 
-----------------------
15-10-2025 16:05:10.48628[4][4] - Elapsed time: 0.010 milliseconds
[parse_aiml.php][clean_that][258]
Cleaning Complete. output = 'ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN' 
-----------------------
15-10-2025 16:05:10.48630[4][4] - Elapsed time: 0.018 milliseconds
[intialise_conversation.php][load_that][835]
Loading previous user inputs into the ~INPUT~ array. 
-----------------------
15-10-2025 16:05:10.48632[2][4] - Elapsed time: 0.016 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.48633[2][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => hai
)

 
-----------------------
15-10-2025 16:05:10.48634[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.48635[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning 'hai' 
-----------------------
15-10-2025 16:05:10.48636[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][clean_that][251]
Cleaning up the ~THAT~ tag: 'hai' 
-----------------------
15-10-2025 16:05:10.48637[4][4] - Elapsed time: 0.012 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'hai' 
-----------------------
15-10-2025 16:05:10.48639[4][4] - Elapsed time: 0.013 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'HAI' 
-----------------------
15-10-2025 16:05:10.48640[4][4] - Elapsed time: 0.010 milliseconds
[parse_aiml.php][clean_that][258]
Cleaning Complete. output = 'HAI' 
-----------------------
15-10-2025 16:05:10.48641[2][4] - Elapsed time: 0.011 milliseconds
[intialise_conversation.php][push_on_front_convoArr][226]
Pushing 'HAI' to the front of the [input] array 
-----------------------
15-10-2025 16:05:10.48644[4][4] - Elapsed time: 0.030 milliseconds
[intialise_conversation.php][load_blank_array_element][62]
Loading blank input array 
-----------------------
15-10-2025 16:05:10.48646[2][4] - Elapsed time: 0.021 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.48647[2][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => hai
)

 
-----------------------
15-10-2025 16:05:10.48648[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.48649[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning 'hai' 
-----------------------
15-10-2025 16:05:10.48650[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][clean_that][251]
Cleaning up the ~THAT~ tag: 'hai' 
-----------------------
15-10-2025 16:05:10.48651[4][4] - Elapsed time: 0.011 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'hai' 
-----------------------
15-10-2025 16:05:10.48653[4][4] - Elapsed time: 0.013 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'HAI' 
-----------------------
15-10-2025 16:05:10.48654[4][4] - Elapsed time: 0.010 milliseconds
[parse_aiml.php][clean_that][258]
Cleaning Complete. output = 'HAI' 
-----------------------
15-10-2025 16:05:10.48655[2][4] - Elapsed time: 0.011 milliseconds
[intialise_conversation.php][push_on_front_convoArr][226]
Pushing 'HAI' to the front of the [input] array 
-----------------------
15-10-2025 16:05:10.48702[2][4] - Elapsed time: 0.474 milliseconds
[intialise_conversation.php][load_bot_config][343]
Loading config data for the current bot. 
-----------------------
15-10-2025 16:05:10.48705[3][4] - Elapsed time: 0.025 milliseconds
[intialise_conversation.php][load_bot_config][352]
load bot config SQL: SELECT * FROM `si2h6234_dbdavid`.`bots` WHERE bot_id = 1; 
-----------------------
15-10-2025 16:05:10.48746[4][4] - Elapsed time: 0.413 milliseconds
[intialise_conversation.php][load_bot_config][357]
Loading bot details from the database. 
-----------------------
15-10-2025 16:05:10.48749[0][4] - Elapsed time: 0.029 milliseconds
[conversation_start.php][Called outside of function][220]
Default debug level = 4 
-----------------------
15-10-2025 16:05:10.48750[0][4] - Elapsed time: 0.012 milliseconds
[conversation_start.php][Called outside of function][222]
Current debug level = 4 
-----------------------
15-10-2025 16:05:10.48751[0][4] - Elapsed time: 0.012 milliseconds
[conversation_start.php][Called outside of function][235]
Say = HEI LOQBOT: raw say = hei loqbot 
-----------------------
15-10-2025 16:05:10.48752[4][4] - Elapsed time: 0.012 milliseconds
[intialise_conversation.php][add_new_conversation_vars][184]
New conversation vars 
-----------------------
15-10-2025 16:05:10.48754[2][4] - Elapsed time: 0.013 milliseconds
[intialise_conversation.php][push_on_front_convoArr][226]
Pushing 'HEI LOQBOT' to the front of the [user_say] array 
-----------------------
15-10-2025 16:05:10.48755[4][4] - Elapsed time: 0.015 milliseconds
[intialise_conversation.php][load_blank_array_element][62]
Loading blank user_say array 
-----------------------
15-10-2025 16:05:10.48758[0][4] - Elapsed time: 0.023 milliseconds
[intialise_conversation.php][add_new_conversation_vars][188]
User RAW = hei loqbot, RAW say = hei loqbot 
-----------------------
15-10-2025 16:05:10.48759[2][4] - Elapsed time: 0.013 milliseconds
[intialise_conversation.php][push_on_front_convoArr][226]
Pushing 'hei loqbot' to the front of the [input] array 
-----------------------
15-10-2025 16:05:10.48761[4][4] - Elapsed time: 0.017 milliseconds
[make_conversation.php][make_conversation][22]
Making conversation 
-----------------------
15-10-2025 16:05:10.48762[4][4] - Elapsed time: 0.013 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'HEI LOQBOT' 
-----------------------
15-10-2025 16:05:10.48764[4][4] - Elapsed time: 0.018 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'HEI LOQBOT' 
-----------------------
15-10-2025 16:05:10.48765[4][4] - Elapsed time: 0.012 milliseconds
[find_aiml.php][get_aiml_to_parse][909]
Running all functions to get the correct aiml from the DB 
-----------------------
15-10-2025 16:05:10.48804[4][4] - Elapsed time: 0.393 milliseconds
[find_aiml.php][find_userdefined_aiml][821]
Looking for user defined responses 
-----------------------
15-10-2025 16:05:10.48808[3][4] - Elapsed time: 0.036 milliseconds
[find_aiml.php][find_userdefined_aiml][870]
User defined SQL:
SELECT `id`, `bot_id`, `pattern`, `thatpattern`, `template` FROM `si2h6234_dbdavid`.`aiml_userdefined` WHERE
    `bot_id` = 1 AND
    `user_id` = '65491f288a916512f50b688f84df9028'
    AND (
        'HEI LOQBOT' LIKE (REPLACE(REPLACE(`pattern`, '*', '%'), '_', '%'))
        OR 'ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN' LIKE (REPLACE(REPLACE(`thatpattern`, '*', '%'), '_', '%')))
   ORDER BY `id` ASC, `pattern` ASC, `thatpattern` ASC; 
-----------------------
15-10-2025 16:05:10.48853[2][4] - Elapsed time: 0.448 milliseconds
[find_aiml.php][find_userdefined_aiml][896]
User defined rows found: '0' 
-----------------------
15-10-2025 16:05:10.48855[4][4] - Elapsed time: 0.020 milliseconds
[find_aiml.php][find_aiml_matches][975]
Finding the aiml matches from the DB 
-----------------------
15-10-2025 16:05:10.48856[4][4] - Elapsed time: 0.011 milliseconds
[find_aiml.php][find_aiml_matches][981]
Bot ID = 1. Bot Parent ID = 1. 
-----------------------
15-10-2025 16:05:10.48897[4][4] - Elapsed time: 0.409 milliseconds
[find_aiml.php][find_aiml_matches][992]
Stored topic = '' 
-----------------------
15-10-2025 16:05:10.48900[3][4] - Elapsed time: 0.033 milliseconds
[find_aiml.php][find_aiml_matches][1052]
Core Match AIML sql:
SELECT `id`, `bot_id`, `pattern`, `thatpattern`, `topic`, `filename`, `template` FROM `si2h6234_dbdavid`.`aiml` WHERE
    bot_id = 1 AND (
        'HEI LOQBOT' LIKE (REPLACE(REPLACE(`pattern`, '*', '%'), '_', '%'))
        OR 'ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN' LIKE (REPLACE(REPLACE(`thatpattern`, '*', '%'), '_', '%'))
        OR `pattern` LIKE 'RANDOM PICKUP LINE'
    )
    # ORDER BY `id` ASC, `topic` DESC, `pattern` ASC, `thatpattern` ASC; 
-----------------------
15-10-2025 16:05:10.48954[3][4] - Elapsed time: 0.542 milliseconds
[find_aiml.php][find_aiml_matches][1054]
Query Process time... 
-----------------------
15-10-2025 16:05:10.48956[2][4] - Elapsed time: 0.021 milliseconds
[find_aiml.php][find_aiml_matches][1061]
FOUND: (4) potential AIML matches 
-----------------------
15-10-2025 16:05:10.48996[1][4] - Elapsed time: 0.396 milliseconds
[find_aiml.php][unset_all_bad_pattern_matches][35]
Current THAT = ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN 
-----------------------
15-10-2025 16:05:10.48998[4][4] - Elapsed time: 0.020 milliseconds
[find_aiml.php][unset_all_bad_pattern_matches][48]
NEW FUNC Searching through 4 rows to unset bad matches 
-----------------------
15-10-2025 16:05:10.48999[4][4] - Elapsed time: 0.011 milliseconds
[find_aiml.php][unset_all_bad_pattern_matches][62]
Blue 5 to Blue leader. Starting my run now! Looking for 'HEI LOQBOT' 
-----------------------
15-10-2025 16:05:10.49028[4][4] - Elapsed time: 0.296 milliseconds
[find_aiml.php][unset_all_bad_pattern_matches][195]
Found 2 relevant rows 
-----------------------
15-10-2025 16:05:10.49031[4][4] - Elapsed time: 0.023 milliseconds
[find_aiml.php][score_matches][255]
Scoring the matches. 
-----------------------
15-10-2025 16:05:10.49081[4][4] - Elapsed time: 0.499 milliseconds
[find_aiml.php][score_matches][548]
Sorted array $allrows:
Array
(
    [0] => Array
        (
            [id] => 35
            [bot_id] => 1
            [pattern] => HEI *
            [thatpattern] => 
            [topic] => 
            [filename] => LoqBot.aiml
            [template] => <random>
      <li>Wah hei <star/>! Lagi pada ngapain nih?</li>
      <li>Halo <star/>! Gimana kabarnya? Ada yang mau diceritain?</li>
    </random>
            [score] => 254
            [current_that] => aduh aku bingung nih bisa kasih tau maksud kamu dengan kata yang lain
            [aiml_id] => 35
            [track_score] => current bot (250 points), no thatpattern to match (1 point), direct word match: hei (2 points), star word match (1 points)
        )

    [1] => Array
        (
            [id] => 45
            [bot_id] => 1
            [pattern] => *
            [thatpattern] => 
            [topic] => 
            [filename] => LoqBot.aiml
            [template] => <random>
      <li>Maaf ya, suaramu kurang jelas. Bisa ulangi lagi pelan-pelan?</li>
      <li>Aduh, aku bingung nih. Bisa kasih tau maksud kamu dengan kata yang lain?</li>
    </random>
            [score] => 252
            [current_that] => aduh aku bingung nih bisa kasih tau maksud kamu dengan kata yang lain
            [aiml_id] => 45
            [track_score] => current bot (250 points), no thatpattern to match (1 point), pattern star match (1 points)
        )

)
 
-----------------------
15-10-2025 16:05:10.49084[2][4] - Elapsed time: 0.033 milliseconds
[find_aiml.php][get_highest_scoring_row][642]
Final candidates:

Array
(
    [0] => Array
        (
            [id] => 35
            [bot_id] => 1
            [pattern] => HEI *
            [thatpattern] => 
            [topic] => 
            [filename] => LoqBot.aiml
            [template] => <random>
      <li>Wah hei <star/>! Lagi pada ngapain nih?</li>
      <li>Halo <star/>! Gimana kabarnya? Ada yang mau diceritain?</li>
    </random>
            [score] => 254
            [current_that] => aduh aku bingung nih bisa kasih tau maksud kamu dengan kata yang lain
            [aiml_id] => 35
            [track_score] => current bot (250 points), no thatpattern to match (1 point), direct word match: hei (2 points), star word match (1 points)
        )

)

 
-----------------------
15-10-2025 16:05:10.49136[4][4] - Elapsed time: 0.522 milliseconds
[find_aiml.php][get_highest_scoring_row][697]
Best Response: Array
(
    [id] => 35
    [bot_id] => 1
    [pattern] => HEI *
    [thatpattern] => 
    [topic] => 
    [filename] => LoqBot.aiml
    [template] => <random>
      <li>Wah hei <star/>! Lagi pada ngapain nih?</li>
      <li>Halo <star/>! Gimana kabarnya? Ada yang mau diceritain?</li>
    </random>
    [score] => 254
    [current_that] => aduh aku bingung nih bisa kasih tau maksud kamu dengan kata yang lain
    [aiml_id] => 35
    [track_score] => current bot (250 points), no thatpattern to match (1 point), direct word match: hei (2 points), star word match (1 points)
)
 
-----------------------
15-10-2025 16:05:10.49138[2][4] - Elapsed time: 0.014 milliseconds
[find_aiml.php][get_highest_scoring_row][698]
No results found, so none to pick from. 
-----------------------
15-10-2025 16:05:10.49141[4][4] - Elapsed time: 0.030 milliseconds
[find_aiml.php][get_aiml_to_parse][960]
Will be parsing id:35 (HEI *) 
-----------------------
15-10-2025 16:05:10.49143[3][4] - Elapsed time: 0.028 milliseconds
[parse_aiml.php][parse_matched_aiml][213]
Run the aiml parse in normal mode (normal or srai) 
-----------------------
15-10-2025 16:05:10.49145[2][4] - Elapsed time: 0.014 milliseconds
[parse_aiml.php][set_wildcards][297]
Setting Wildcards. Pattern = 'HEI *' 
-----------------------
15-10-2025 16:05:10.49146[2][4] - Elapsed time: 0.012 milliseconds
[parse_aiml.php][set_wildcards][306]
We have pattern stars to process! 
-----------------------
15-10-2025 16:05:10.49147[2][4] - Elapsed time: 0.012 milliseconds
[parse_aiml.php][set_wildcards][310]
RegEx string = ~HEI (.+)$~siuU: Searching hei loqbot for a match. 
-----------------------
15-10-2025 16:05:10.49154[2][4] - Elapsed time: 0.068 milliseconds
[parse_aiml.php][set_wildcards][313]
Array
(
    [0] => Array
        (
            [0] => hei loqbot
        )

    [1] => Array
        (
            [0] => loqbot
        )

)
 
-----------------------
15-10-2025 16:05:10.49156[2][4] - Elapsed time: 0.018 milliseconds
[parse_aiml.php][set_wildcards][318]
Adding 'loqbot' to the stars stack. 
-----------------------
15-10-2025 16:05:10.49157[2][4] - Elapsed time: 0.013 milliseconds
[parse_aiml.php][set_wildcards][320]
Star array = Array
(
    [1] => loqbot
)
 
-----------------------
15-10-2025 16:05:10.49158[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][set_wildcards][329]
Checking for wildcards in pattern-side THAT 
-----------------------
15-10-2025 16:05:10.49159[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][set_wildcards][361]
Checking for wildcards in pattern-side TOPIC 
-----------------------
15-10-2025 16:05:10.49162[2][4] - Elapsed time: 0.022 milliseconds
[parse_aiml.php][set_wildcards][394]
AIML array now = Array
(
    [aiml_id] => 35
    [category_id] => 35
    [html_template] => 
    [lookingfor] => HEI LOQBOT
    [pattern] => HEI *
    [score] => 254
    [stars] => Array
        (
            [1] => loqbot
        )

    [template] => <random>
      <li>Wah hei <star/>! Lagi pada ngapain nih?</li>
      <li>Halo <star/>! Gimana kabarnya? Ada yang mau diceritain?</li>
    </random>
    [thatpattern] => 
    [that_stars] => Array
        (
            [1] => 
        )

    [topic] => 
    [topic_stars] => Array
        (
        )

    [user_raw] => hei loqbot
)
 
-----------------------
15-10-2025 16:05:10.49163[2][4] - Elapsed time: 0.017 milliseconds
[parse_aiml_as_XML.php][parse_aiml_as_XML][22]
Parsing the AIML template as XML 
-----------------------
15-10-2025 16:05:10.49165[2][4] - Elapsed time: 0.015 milliseconds
[parse_aiml_as_XML.php][add_text_tags][93]
Adding some TEXT tags into the template, just because I can... 
-----------------------
15-10-2025 16:05:10.49175[4][4] - Elapsed time: 0.103 milliseconds
[parse_aiml_as_XML.php][add_text_tags][120]
Returning template:
<template><random><li><text>Wah hei </text><star/><text>! Lagi pada ngapain nih?</text></li><li><text>Halo </text><star/><text>! Gimana kabarnya? Ada yang mau diceritain?</text></li></random></template> 
-----------------------
15-10-2025 16:05:10.49198[2][4] - Elapsed time: 0.230 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][201]
Recursively parsing the AIML template. 
-----------------------
15-10-2025 16:05:10.49209[4][4] - Elapsed time: 0.113 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][214]
Processing element template at level 0. element XML = <?xml version="1.0"?>
<template><random><li><text>Wah hei </text><star/><text>! Lagi pada ngapain nih?</text></li><li><text>Halo </text><star/><text>! Gimana kabarnya? Ada yang mau diceritain?</text></li></random></template>
 
-----------------------
15-10-2025 16:05:10.49211[4][4] - Elapsed time: 0.017 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][242]
function parse_template_tag does not exist. Parsing tag as text. 
-----------------------
15-10-2025 16:05:10.49214[2][4] - Elapsed time: 0.029 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][201]
Recursively parsing the AIML template. 
-----------------------
15-10-2025 16:05:10.49218[4][4] - Elapsed time: 0.039 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][214]
Processing element random at level 1. element XML = <random><li><text>Wah hei </text><star/><text>! Lagi pada ngapain nih?</text></li><li><text>Halo </text><star/><text>! Gimana kabarnya? Ada yang mau diceritain?</text></li></random> 
-----------------------
15-10-2025 16:05:10.49219[4][4] - Elapsed time: 0.014 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][225]
Function parse_random_tag does exist. Processing now. 
-----------------------
15-10-2025 16:05:10.49220[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][229]
Passing element random to the parse_random_tag function 
-----------------------
15-10-2025 16:05:10.49222[2][4] - Elapsed time: 0.021 milliseconds
[parse_aiml_as_XML.php][parse_random_tag][496]
Parsing a RANDOM tag, or doing some stargazing, or fomenting chaos, or... 
-----------------------
15-10-2025 16:05:10.49231[4][4] - Elapsed time: 0.086 milliseconds
[parse_aiml_as_XML.php][parse_random_tag][498]
Pick array:
Array
(
    [0] => SimpleXMLElement Object
        (
            [text] => Array
                (
                    [0] => Wah hei 
                    [1] => ! Lagi pada ngapain nih?
                )

            [star] => SimpleXMLElement Object
                (
                )

        )

    [1] => SimpleXMLElement Object
        (
            [text] => Array
                (
                    [0] => Halo 
                    [1] => ! Gimana kabarnya? Ada yang mau diceritain?
                )

            [star] => SimpleXMLElement Object
                (
                )

        )

)
 
-----------------------
15-10-2025 16:05:10.49233[4][4] - Elapsed time: 0.016 milliseconds
[parse_aiml_as_XML.php][parse_random_tag][500]
Picking option #1 from random tag.
 
-----------------------
15-10-2025 16:05:10.49234[2][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][201]
Recursively parsing the AIML template. 
-----------------------
15-10-2025 16:05:10.49236[4][4] - Elapsed time: 0.022 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][214]
Processing element li at level 2. element XML = <li><text>Halo </text><star/><text>! Gimana kabarnya? Ada yang mau diceritain?</text></li> 
-----------------------
15-10-2025 16:05:10.49237[4][4] - Elapsed time: 0.013 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][242]
function parse_li_tag does not exist. Parsing tag as text. 
-----------------------
15-10-2025 16:05:10.49239[2][4] - Elapsed time: 0.015 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][201]
Recursively parsing the AIML template. 
-----------------------
15-10-2025 16:05:10.49240[4][4] - Elapsed time: 0.016 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][214]
Processing element text at level 3. element XML = <text>Halo </text> 
-----------------------
15-10-2025 16:05:10.49243[4][4] - Elapsed time: 0.025 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][225]
Function parse_text_tag does exist. Processing now. 
-----------------------
15-10-2025 16:05:10.49244[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][229]
Passing element text to the parse_text_tag function 
-----------------------
15-10-2025 16:05:10.49245[2][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parse_text_tag][281]
Parsing a TEXT tag. 
-----------------------
15-10-2025 16:05:10.49247[4][4] - Elapsed time: 0.013 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][234]
Adding 'Halo ' to the response array. tag name is text 
-----------------------
15-10-2025 16:05:10.49248[2][4] - Elapsed time: 0.013 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.49249[2][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => Halo 
)

 
-----------------------
15-10-2025 16:05:10.49250[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.49252[4][4] - Elapsed time: 0.013 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning 'Halo ' 
-----------------------
15-10-2025 16:05:10.49253[4][4] - Elapsed time: 0.013 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][262]
Adding 'Halo ' to the response array. tag name is li. 
-----------------------
15-10-2025 16:05:10.49254[2][4] - Elapsed time: 0.016 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][201]
Recursively parsing the AIML template. 
-----------------------
15-10-2025 16:05:10.49256[4][4] - Elapsed time: 0.015 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][214]
Processing element star at level 3. element XML = <star/> 
-----------------------
15-10-2025 16:05:10.49257[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][225]
Function parse_star_tag does exist. Processing now. 
-----------------------
15-10-2025 16:05:10.49258[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][229]
Passing element star to the parse_star_tag function 
-----------------------
15-10-2025 16:05:10.49259[2][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parse_star_tag][297]
Parsing a STAR tag. 
-----------------------
15-10-2025 16:05:10.49261[4][4] - Elapsed time: 0.014 milliseconds
[parse_aiml_as_XML.php][parse_star_tag][299]
parse_star_tag called from the star tag at level 3. element = <star/> 
-----------------------
15-10-2025 16:05:10.49263[4][4] - Elapsed time: 0.018 milliseconds
[parse_aiml_as_XML.php][parse_star_tag][309]
Current AIML Array:
Array
(
    [user_raw] => hei loqbot
    [lookingfor] => HEI LOQBOT
    [category_id] => 35
    [pattern] => HEI *
    [thatpattern] => 
    [template] => <random>
      <li>Wah hei <star/>! Lagi pada ngapain nih?</li>
      <li>Halo <star/>! Gimana kabarnya? Ada yang mau diceritain?</li>
    </random>
    [html_template] => 
    [topic] => 
    [score] => 254
    [aiml_id] => 35
    [stars] => Array
        (
            [1] => loqbot
        )

    [that_stars] => Array
        (
            [1] => 
        )

    [topic_stars] => Array
        (
        )

)
 
-----------------------
15-10-2025 16:05:10.49264[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][parse_star_tag][310]
star index = 1. 
-----------------------
15-10-2025 16:05:10.49265[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parse_star_tag][314]
Adding 'loqbot' to the response array. 
-----------------------
15-10-2025 16:05:10.49266[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parse_star_tag][316]
Index value = 1, star value = loqbot 
-----------------------
15-10-2025 16:05:10.49267[2][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.49269[2][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => loqbot
)

 
-----------------------
15-10-2025 16:05:10.49270[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.49271[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning 'loqbot' 
-----------------------
15-10-2025 16:05:10.49272[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][234]
Adding 'loqbot' to the response array. tag name is star 
-----------------------
15-10-2025 16:05:10.49273[2][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.49274[2][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => loqbot
)

 
-----------------------
15-10-2025 16:05:10.49275[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.49276[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning 'loqbot' 
-----------------------
15-10-2025 16:05:10.49277[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][262]
Adding 'loqbot' to the response array. tag name is li. 
-----------------------
15-10-2025 16:05:10.49279[2][4] - Elapsed time: 0.013 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][201]
Recursively parsing the AIML template. 
-----------------------
15-10-2025 16:05:10.49280[4][4] - Elapsed time: 0.016 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][214]
Processing element text at level 3. element XML = <text>! Gimana kabarnya? Ada yang mau diceritain?</text> 
-----------------------
15-10-2025 16:05:10.49282[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][225]
Function parse_text_tag does exist. Processing now. 
-----------------------
15-10-2025 16:05:10.49283[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][229]
Passing element text to the parse_text_tag function 
-----------------------
15-10-2025 16:05:10.49284[2][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][parse_text_tag][281]
Parsing a TEXT tag. 
-----------------------
15-10-2025 16:05:10.49285[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][234]
Adding '! Gimana kabarnya? Ada yang mau diceritain?' to the response array. tag name is text 
-----------------------
15-10-2025 16:05:10.49286[2][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.49287[2][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => ! Gimana kabarnya? Ada yang mau diceritain?
)

 
-----------------------
15-10-2025 16:05:10.49288[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.49289[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning '! Gimana kabarnya? Ada yang mau diceritain?' 
-----------------------
15-10-2025 16:05:10.49291[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][262]
Adding '! Gimana kabarnya? Ada yang mau diceritain?' to the response array. tag name is li. 
-----------------------
15-10-2025 16:05:10.49292[2][4] - Elapsed time: 0.013 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.49293[2][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => Halo 
    [1] => loqbot
    [2] => ! Gimana kabarnya? Ada yang mau diceritain?
)

 
-----------------------
15-10-2025 16:05:10.49294[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.49295[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning 'Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?' 
-----------------------
15-10-2025 16:05:10.49296[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parse_random_tag][503]
Chose Random Response of 'Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?' for output. 
-----------------------
15-10-2025 16:05:10.49298[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][234]
Adding 'Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?' to the response array. tag name is random 
-----------------------
15-10-2025 16:05:10.49299[2][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.49300[2][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?
)

 
-----------------------
15-10-2025 16:05:10.49301[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.49302[4][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning 'Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?' 
-----------------------
15-10-2025 16:05:10.49303[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][parseTemplateRecursive][262]
Adding 'Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?' to the response array. tag name is template. 
-----------------------
15-10-2025 16:05:10.49305[2][4] - Elapsed time: 0.020 milliseconds
[parse_aiml_as_XML.php][implode_recursive][137]
Imploding an array into a string. (recursively, if necessary) 
-----------------------
15-10-2025 16:05:10.49307[2][4] - Elapsed time: 0.012 milliseconds
[parse_aiml_as_XML.php][implode_recursive][138]
Input: Array
(
    [0] => Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?
)

 
-----------------------
15-10-2025 16:05:10.49308[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][155]
The variable $input is of type array 
-----------------------
15-10-2025 16:05:10.49309[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml_as_XML.php][implode_recursive][185]
Imploding complete. Returning 'Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?' 
-----------------------
15-10-2025 16:05:10.49310[4][4] - Elapsed time: 0.015 milliseconds
[parse_aiml_as_XML.php][parse_aiml_as_XML][47]
Completed parsing the template. The bot will say: Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain? 
-----------------------
15-10-2025 16:05:10.49312[4][4] - Elapsed time: 0.020 milliseconds
[parse_aiml.php][parse_matched_aiml][227]
normal - Saving for next turn 
-----------------------
15-10-2025 16:05:10.49313[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][save_for_nextturn][271]
Saving that and that_raw for next turn 
-----------------------
15-10-2025 16:05:10.49315[2][4] - Elapsed time: 0.012 milliseconds
[intialise_conversation.php][push_on_front_convoArr][226]
Pushing 'Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?' to the front of the [that_raw] array 
-----------------------
15-10-2025 16:05:10.49316[4][4] - Elapsed time: 0.016 milliseconds
[intialise_conversation.php][load_blank_array_element][62]
Loading blank that_raw array 
-----------------------
15-10-2025 16:05:10.49320[2][4] - Elapsed time: 0.040 milliseconds
[intialise_conversation.php][push_on_front_convoArr][226]
Pushing 'Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?' to the front of the [that] array 
-----------------------
15-10-2025 16:05:10.49322[4][4] - Elapsed time: 0.022 milliseconds
[parse_aiml.php][clean_that][251]
Cleaning up the ~THAT~ tag: 'Halo loqbot !' 
-----------------------
15-10-2025 16:05:10.49324[4][4] - Elapsed time: 0.013 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'Halo loqbot !' 
-----------------------
15-10-2025 16:05:10.49326[4][4] - Elapsed time: 0.020 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'HALO LOQBOT' 
-----------------------
15-10-2025 16:05:10.49327[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][clean_that][258]
Cleaning Complete. output = 'HALO LOQBOT' 
-----------------------
15-10-2025 16:05:10.49328[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][clean_that][251]
Cleaning up the ~THAT~ tag: 'Gimana kabarnya?' 
-----------------------
15-10-2025 16:05:10.49329[4][4] - Elapsed time: 0.011 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'Gimana kabarnya?' 
-----------------------
15-10-2025 16:05:10.49330[4][4] - Elapsed time: 0.015 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'GIMANA KABARNYA' 
-----------------------
15-10-2025 16:05:10.49331[4][4] - Elapsed time: 0.010 milliseconds
[parse_aiml.php][clean_that][258]
Cleaning Complete. output = 'GIMANA KABARNYA' 
-----------------------
15-10-2025 16:05:10.49333[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][clean_that][251]
Cleaning up the ~THAT~ tag: 'Ada yang mau diceritain?' 
-----------------------
15-10-2025 16:05:10.49334[4][4] - Elapsed time: 0.012 milliseconds
[misc_functions.php][normalize_text][125]
Begin normalization - text = 'Ada yang mau diceritain?' 
-----------------------
15-10-2025 16:05:10.49335[4][4] - Elapsed time: 0.014 milliseconds
[misc_functions.php][normalize_text][150]
Normalization complete. Text = 'ADA YANG MAU DICERITAIN' 
-----------------------
15-10-2025 16:05:10.49336[4][4] - Elapsed time: 0.011 milliseconds
[parse_aiml.php][clean_that][258]
Cleaning Complete. output = 'ADA YANG MAU DICERITAIN' 
-----------------------
15-10-2025 16:05:10.49339[2][4] - Elapsed time: 0.022 milliseconds
[intialise_conversation.php][push_on_front_convoArr][226]
Pushing 'Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?' to the front of the [parsed_template] array 
-----------------------
15-10-2025 16:05:10.49340[4][4] - Elapsed time: 0.014 milliseconds
[intialise_conversation.php][load_blank_array_element][62]
Loading blank parsed_template array 
-----------------------
15-10-2025 16:05:10.49343[2][4] - Elapsed time: 0.033 milliseconds
[intialise_conversation.php][push_on_front_convoArr][226]
Pushing '<random>
      <li>Wah hei <star/>! Lagi pada ngapain nih?</li>
      <li>Halo <star/>! Gimana kabarnya? Ada yang mau diceritain?</li>
    </random>' to the front of the [template] array 
-----------------------
15-10-2025 16:05:10.49345[4][4] - Elapsed time: 0.016 milliseconds
[intialise_conversation.php][load_blank_array_element][62]
Loading blank template array 
-----------------------
15-10-2025 16:05:10.49347[2][4] - Elapsed time: 0.022 milliseconds
[intialise_conversation.php][log_conversation][403]
Saving the conversation to the DB. 
-----------------------
15-10-2025 16:05:10.49349[3][4] - Elapsed time: 0.025 milliseconds
[intialise_conversation.php][log_conversation][442]
Saving conservation SQL: INSERT INTO `si2h6234_dbdavid`.`conversation_log` (
      `id` ,
      `input` ,
      `response` ,
      `user_id` ,
      `convo_id` ,
      `bot_id` ,
      `timestamp`
    )
    VALUES (
      NULL ,
      'hei loqbot',
      'Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?',
      7,
      '65491f288a916512f50b688f84df9028',
      1,
      CURRENT_TIMESTAMP
    ) 
-----------------------
15-10-2025 16:05:10.49549[4][4] - Elapsed time: 1.996 milliseconds
[intialise_conversation.php][write_to_session][140]
Saving to session 
-----------------------
15-10-2025 16:05:10.49583[3][4] - Elapsed time: 0.336 milliseconds
[display_conversation.php][get_conversation_to_display][59]
get_conversation SQL: SELECT * FROM `si2h6234_dbdavid`.`conversation_log` WHERE
        `user_id` = :user_id
        AND `bot_id` = :bot_id
        AND `convo_id` = :convo_id
        ORDER BY id DESC  LIMIT 1 
-----------------------
15-10-2025 16:05:10.49626[2][4] - Elapsed time: 0.433 milliseconds
[display_conversation.php][get_conversation_to_display][77]
Found '1' lines of conversation 
-----------------------
15-10-2025 16:05:10.49628[4][4] - Elapsed time: 0.019 milliseconds
[display_conversation.php][get_conversation][92]
Processing conversation as json 
-----------------------
15-10-2025 16:05:10.49629[2][4] - Elapsed time: 0.013 milliseconds
[display_conversation.php][get_json][150]
Outputting response as JSON 
-----------------------
15-10-2025 16:05:10.49632[4][4] - Elapsed time: 0.032 milliseconds
[display_conversation.php][get_json][164]
Returning JSON string: {"convo_id":"65491f288a916512f50b688f84df9028","usersay":"hei loqbot","botsay":"Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?","botData":{"convo_id":"65491f288a916512f50b688f84df9028","bot_name":"Loq Bot","bot_id":"1","format":"json","unknown_user":"Seeker","user_name":"Seeker","user_id":"7","totallines":1,"rawSay":"hei loqbot","conversation_lines":"1","remember_up_to":"10","debugemail":"24n10025@student.unika.ac.id","debug_level":"4","debugmode":1,"save_state":"session","default_aiml_pattern":"RANDOM PICKUP LINE","bot_parent_id":"1","aimlData":{"id":"35","bot_id":"1","pattern":"HEI *","thatpattern":"","topic":"","filename":"LoqBot.aiml","template":"<random>\n      <li>Wah hei <star\/>! Lagi pada ngapain nih?<\/li>\n      <li>Halo <star\/>! Gimana kabarnya? Ada yang mau diceritain?<\/li>\n    <\/random>","score":254,"current_that":"aduh aku bingung nih bisa kasih tau maksud kamu dengan kata yang lain","aiml_id":"35","track_score":"current bot (250 points), no thatpattern to match (1 point), direct word match: hei (2 points), star word match (1 points)"}}} 
-----------------------
15-10-2025 16:05:10.49684[2][4] - Elapsed time: 0.515 milliseconds
[conversation_start.php][Called outside of function][260]
Closing Database 
-----------------------
15-10-2025 16:05:10.49689[0][4] - Elapsed time: 0.055 milliseconds
[conversation_start.php][Called outside of function][266]
Conversation Ending. Elapsed time: 27.912 milliseconds. 
-----------------------
Debug Level: 4
-----------------------
Debug Mode: 1
-----------------------
CONVERSATION ARRAY
-----------------------
Array
(
    [say] => hei loqbot
    [conversation] => Array
        (
            [convo_id] => 65491f288a916512f50b688f84df9028
            [bot_name] => Loq Bot
            [bot_id] => 1
            [format] => json
            [unknown_user] => Seeker
            [user_name] => Seeker
            [user_id] => 7
            [totallines] => 1
            [rawSay] => hei loqbot
            [conversation_lines] => 1
            [remember_up_to] => 10
            [debugemail] => 24n10025@student.unika.ac.id
            [debug_level] => 4
            [debugmode] => 1
            [save_state] => session
            [default_aiml_pattern] => RANDOM PICKUP LINE
            [bot_parent_id] => 1
            [aimlData] => Array
                (
                    [id] => 35
                    [bot_id] => 1
                    [pattern] => HEI *
                    [thatpattern] => 
                    [topic] => 
                    [filename] => LoqBot.aiml
                    [template] => <random>
      <li>Wah hei <star/>! Lagi pada ngapain nih?</li>
      <li>Halo <star/>! Gimana kabarnya? Ada yang mau diceritain?</li>
    </random>
                    [score] => 254
                    [current_that] => aduh aku bingung nih bisa kasih tau maksud kamu dengan kata yang lain
                    [aiml_id] => 35
                    [track_score] => current bot (250 points), no thatpattern to match (1 point), direct word match: hei (2 points), star word match (1 points)
                )

        )

    [aiml] => Array
        (
            [user_raw] => hei loqbot
            [lookingfor] => HEI LOQBOT
            [category_id] => 35
            [pattern] => HEI *
            [thatpattern] => 
            [template] => <random>
      <li>Wah hei <star/>! Lagi pada ngapain nih?</li>
      <li>Halo <star/>! Gimana kabarnya? Ada yang mau diceritain?</li>
    </random>
            [html_template] => 
            [topic] => 
            [score] => 254
            [aiml_id] => 35
            [stars] => Array
                (
                    [1] => loqbot
                )

            [that_stars] => Array
                (
                    [1] => 
                )

            [topic_stars] => Array
                (
                )

            [parsed_template] => Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?
        )

    [client_properties] => Array
        (
            [ip_address] => 112.215.160.30
            [name] => Seeker
        )

    [raw_that] => Array
        (
            [1] => Array
                (
                    [0] => Aduh, aku bingung nih
                    [1] =>  Bisa kasih tau maksud kamu dengan kata yang lain?
                )

            [2] => Array
                (
                    [0] => Maaf, aku belum paham maksud kamu
                    [1] =>  Bisa diulang dengan cara lain?
                )

        )

    [that] => Array
        (
            [1] => Array
                (
                    [1] => ADA YANG MAU DICERITAIN
                    [2] => GIMANA KABARNYA
                    [3] => HALO LOQBOT
                )

            [2] => Array
                (
                    [1] => ADUH AKU BINGUNG NIH BISA KASIH TAU MAKSUD KAMU DENGAN KATA YANG LAIN
                )

            [3] => Array
                (
                    [1] => MAAF AKU BELUM PAHAM MAKSUD KAMU BISA DIULANG DENGAN CARA LAIN
                )

            [4] => 
            [5] => 
            [6] => 
            [7] => 
            [8] => 
            [9] => 
            [10] => 
            [12] => 
        )

    [input] => Array
        (
            [1] => hei loqbot
            [2] => HAI
            [3] => HAI
            [4] => 
            [5] => 
            [6] => 
            [7] => 
            [8] => 
            [9] => 
            [10] => 
        )

    [time_start] => 1760519110.4689
    [user_say] => Array
        (
            [1] => HEI LOQBOT
            [2] => 
            [3] => 
            [4] => 
            [5] => 
            [6] => 
            [7] => 
            [8] => 
            [9] => 
            [10] => 
        )

    [that_raw] => Array
        (
            [1] => Array
                (
                    [1] => 
                    [2] => Ada yang mau diceritain?
                    [3] => Gimana kabarnya?
                    [4] => Halo loqbot !
                )

            [2] => 
            [3] => 
            [4] => 
            [5] => 
            [6] => 
            [7] => 
            [8] => 
            [9] => 
            [10] => 
            [12] => 
        )

    [parsed_template] => Array
        (
            [1] => Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?
            [2] => 
            [3] => 
            [4] => 
            [5] => 
            [6] => 
            [7] => 
            [8] => 
            [9] => 
            [10] => 
        )

    [template] => Array
        (
            [1] => <random> <li>Wah hei <star/>! Lagi pada ngapain nih?</li> <li>Halo <star/>! Gimana kabarnya? Ada yang mau diceritain?</li> </random>
            [2] => 
            [3] => 
            [4] => 
            [5] => 
            [6] => 
            [7] => 
            [8] => 
            [9] => 
            [10] => 
        )

    [send_to_user] => {"convo_id":"65491f288a916512f50b688f84df9028","usersay":"hei loqbot","botsay":"Halo loqbot ! Gimana kabarnya? Ada yang mau diceritain?","botData":{"convo_id":"65491f288a916512f50b688f84df9028","bot_name":"Loq Bot","bot_id":"1","format":"json","unknown_user":"Seeker","user_name":"Seeker","user_id":"7","totallines":1,"rawSay":"hei loqbot","conversation_lines":"1","remember_up_to":"10","debugemail":"24n10025@student.unika.ac.id","debug_level":"4","debugmode":1,"save_state":"session","default_aiml_pattern":"RANDOM PICKUP LINE","bot_parent_id":"1","aimlData":{"id":"35","bot_id":"1","pattern":"HEI *","thatpattern":"","topic":"","filename":"LoqBot.aiml","template":"<random>\n      <li>Wah hei <star\/>! Lagi pada ngapain nih?<\/li>\n      <li>Halo <star\/>! Gimana kabarnya? Ada yang mau diceritain?<\/li>\n    <\/random>","score":254,"current_that":"aduh aku bingung nih bisa kasih tau maksud kamu dengan kata yang lain","aiml_id":"35","track_score":"current bot (250 points), no thatpattern to match (1 point), direct word match: hei (2 points), star word match (1 points)"}}}
)

-----------------------
Total execution time: 27.912 Milliseconds. Goodbye.