phpBB2 by Przemo
Support forów phpBB2 modified by Przemo

FAQFAQ - PIERWSZA POMOC!!  regulaminREGULAMIN  SzukajSZUKAJ  UżytkownicyUżytkownicy  GrupyGrupy  StatystykiStatystyki
RejestracjaRejestracja  ZalogujZaloguj  DownloadDownload  katalog Forów DyskusyjnychKatalog Forów   FAQ Video tutoriale

Poprzedni temat «» Następny temat
IAI BOT Writer Posts 1.0
Autor Wiadomość
Ekskuator


Posty: 10
Wysłany: 23-10-2006, 17:32   IAI BOT Writer Posts 1.0

Bot czytający i piszący post. Na razie bazy są tylko po angielsku, postaram się je jak najszybciej (można samemu wrzucić własne polskie :D ) przetłumaczyć.
Bot działa na 1.2.5 by Przemo, konfigurowalne w PA
Demo dostępne na: http://www.class2a.easyisp.pl/forum30.htm (zablokowałem gościom pisane, z powodu nagminnego łamania regulaminu forum i działu "Rozmowy z Cyborgiem")
Cytat:

##############################################################
## MOD Nazwa: IAI Bot
## Demo Projeku: http://www.class2a.easyisp.pl/forum30.htm
## MOD Autor: zemaj < zemaj@palgn.com > (James Gay)
## MOD Dostosowanie do phpBB by Przemo 1.12.5: Garfield (Ekskuator)
## Opis: This mod with give your forums an "artifical intelligence" bot based on the ALICE system
## (& Program E by Paul Rydell) which will respond to users' posts/pms in your forum and chat with users.
## MOD Version: 1.0
##
## Poziom instalacji: Wymagający
## Czas instalacji: ~25 minut (+10 lub więcej na instalację plików AIML)
## Piliki do edycji: posting.php
## includes/functions_post.php
## privmsg.php
## includes/usercp_register.php
## admin/modules_data.php
## Dołączone pliki: ~30
##############################################################
## Przed instalacją MODa na forum powinieneś zrobić kopię zapasową wszystkich plików
##############################################################
## PRZED INSTALACJĄ:
##
## Pierwszym krokiem jest wrzucenie na FTP wszystkich plików z tego RAR
## (do katalogu głownego twojego phpbb by przemo).
##
## Uruchom mods/iai/install.php przed edycją plików.
##############################################################
#
#-----[ OTWÓRZ ]------------------------------------------
#
posting.php

#
#-----[ ZNAJDŹ ]------------------------------------------
#
update_post_stats($mode, $post_data, $forum_id, $topic_id, $post_id, $user_id);

#
#-----[ DODAJ PO ]------------------------------------------
#
//
// Begin IAI system
//

// Note: the switch statements here can be quite complicated, so I've used
// some weird setting out. This helps to show exactly what is going on and
// allows me to bear down on the problems that were occuring before.

// Do seed for random replies
list($usec, $sec) = explode(' ', microtime());
mt_srand((float) $sec + ((float) $usec * 100000));
$iai_rand = mt_rand(0, 100);

// Initial should IAI run check
$run_iai =
(
(
$mode == 'newtopic'
||
$mode == 'reply'
)
&&
(
$iai_rand <= $board_config['iai_percentage_all']
)
&&
(
$board_config['iai_percentage_all'] != 0
)
&&
(
$board_config['iai_active_all']
)
) ? TRUE : FALSE;

// Check if forum has settings which overide this
if($post_info['iai_override'])
{
$run_iai = (($iai_rand <= $post_info['iai_percentage']) && ($post_info['iai_percentage'] != 0)) ? TRUE : FALSE;
}

// If IAI is not currently set to run, then it should find any call words
// in the post which might overide this.
// Not in the usual set out, but it allows you to actually understand what's going on.
if(
(
!($run_iai)
)
&&
(
(
$post_info['iai_override']
&&
$post_info['iai_stop_words']
)
||
(
!($post_info['iai_override'])
&&
$board_config['iai_active_all']
)
)
)
{
// See if there is any match in the respond words array.
// I know this system is pretty bad (there must be a faster way), but I haven't had much experience with it, so any help would be greatly appreciated
$res_words = str_replace(", ", ",", $board_config['iai_respond_words']);
$res_words = str_replace("!", "", $res_words);
$res_words = str_replace("?", "", $res_words);
$res_words = str_replace("'", "", $res_words);
$res_words = str_replace('"', '', $res_words);
$res_words = explode(",", $res_words);
$words = str_replace(".", "", $HTTP_POST_VARS['message']);
$words = str_replace("!", "", $words);
$words = str_replace("?", "", $words);
$words = str_replace(",", "", $words);
$words = str_replace("'", "", $words);
$words = str_replace('"', '', $words);
$words = explode(" ", $words);
for($i = 0; $i < count($res_words); $i++)
{
$words = str_replace($res_words[$i] . " ", " " . $res_words[$i] . " ", $words);
$words = str_replace(" " . $res_words[$i], " " . $res_words[$i] . " ", $words);
for($g = 0; $g < count($words); $g++)
{
if($res_words[$i] == $words[$g])
{
$run_iai = TRUE;
}
}
}
}

// START IAI response and entry to db (if active)
if ($run_iai)
{
$iai_root_path = $phpbb_root_path . "mods/iai/";
include($iai_root_path . 'includes/iai_functions.'.$phpEx);

// Initialise variables
$iai_mode = 'reply';
$iai_post_id = '';
$iai_id = $board_config['iai_userid'];
$iai_subject = '';
$iai_username = $board_config['iai_username'];
$iai_topic_type = POST_NORMAL;
$numselects = 0;
$user_id = ($userdata['session_logged_in']) ? $userdata['user_id'] : 0;
// $topic_id should be set already
$sesh_id = $userdata['session_id']; // should NOT be null in any situation
$iai_reply_to = str_replace("is " . $iai_username, "are you", $HTTP_POST_VARS['message']);
$iai_reply_to = str_replace( $iai_username, "you", $iai_reply_to);

// Get IAI reply
$iai_reply = reply($iai_reply_to,$user_id,$topic_id,$sesh_id);
$iai_message = $iai_reply->response;

// prepare IAI message(IAI may have used html, smilies etc...)
$bbcode_uid = ( $bbcode_on ) ? make_bbcode_uid() : '';
$iai_message = str_replace("'", "''", $iai_message);
$iai_message = prepare_message(trim($iai_message), 0, 1, 1, $bbcode_uid);

if ( $error_msg == '' && !empty($iai_message) )
{
// Submit IAI's response to DB & update stats
iai_submit_post($iai_mode, $iai_id, $forum_id, $topic_id, $iai_post_id, $iai_topic_type, 1, 1, 1, 1, $bbcode_uid, str_replace("\'", "''", $iai_username), str_replace("\'", "''", $iai_subject), str_replace("\'", "''", $iai_message));
iai_update_post_stats($forum_id, $topic_id, $iai_post_id, $iai_id);
}
}
// END IAI response and entry to db

//
// END IAI system
//

#
#-----[ OTWÓRZ ]------------------------------------------
#
includes/functions_post.php

#
#-----[ ZNAJDŹ ]------------------------------------------
#
//
// This function will prepare a posted message for
// entry into the database.
//

#
#-----[ DODAJ PRZED ]------------------------------------------
#
//
// Post IAI's response to database
//
function iai_submit_post($mode, &$iai_id, &$forum_id, &$topic_id, &$iai_post_id, &$topic_type, $bbcode_on, $html_on, $smilies_on, $attach_sig, &$bbcode_uid, &$iai_username, &$iai_subject, &$iai_message)
{
global $board_config, $lang, $db, $phpbb_root_path, $phpEx;

//Stores user's IP since IAI has none. Can be changed as wished.
global $user_ip;

$current_time = time();
$iai_post_order = $db->sql_nextid();

$sql = "INSERT INTO " . POSTS_TABLE . " (topic_id, forum_id, poster_id, post_order, post_time, poster_ip, enable_bbcode, enable_html, enable_smilies, enable_sig) VALUES ($topic_id, $forum_id, $iai_id, '$iai_post_order', $current_time, '$user_ip', $bbcode_on, $html_on, $smilies_on, $attach_sig)";
if ( !($result = $db->sql_query($sql, BEGIN_TRANSACTION)) )
{
message_die(GENERAL_ERROR, 'Error in posting', '', __LINE__, __FILE__, $sql);
}

$iai_post_id = $db->sql_nextid();

$sql = "INSERT INTO " . POSTS_TEXT_TABLE . " (post_id, post_subject, bbcode_uid, post_text) VALUES ($iai_post_id, '$iai_subject', '$bbcode_uid', '$iai_message')";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Error in posting', '', __LINE__, __FILE__, $sql);
}

add_search_words($iai_post_id, stripslashes($iai_message), stripslashes($iai_subject));

return false;
}
#
#-----[ ZNAJDŹ ]------------------------------------------
#
function update_post_stats(&$mode, &$post_data, &$forum_id, &$topic_id, &$post_id, &$user_id)

#
#-----[ DODAJ PRZED ]------------------------------------------
#
//
// Update Stats for IAI: must be run AFTER update_post_stats() for original post
//
function iai_update_post_stats(&$forum_id, &$topic_id, &$iai_post_id, &$iai_id)
{
global $db;

//This simply runs the 3 db updating functions (only used for IAI replies).

$sql = "UPDATE " . FORUMS_TABLE . "
SET forum_posts = forum_posts + 1, forum_last_post_id = $iai_post_id
WHERE forum_id = $forum_id";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Error in posting', '', __LINE__, __FILE__, $sql);
}

$sql = "UPDATE " . TOPICS_TABLE . "
SET topic_last_post_id = $iai_post_id, topic_replies = topic_replies + 1
WHERE topic_id = $topic_id";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Error in posting', '', __LINE__, __FILE__, $sql);
}

// Comment out the next 7 lines if you don't want user posts to be updated (it will annoy some users otherwise).
$sql = "UPDATE " . USERS_TABLE . "
SET user_posts = user_posts + 1
WHERE user_id = $iai_id";
if ( !($result = $db->sql_query($sql, END_TRANSACTION)) )
{
message_die(GENERAL_ERROR, 'Error in posting', '', __LINE__, __FILE__, $sql);
}

return;
}
//
// Allows bot to send pms requiring only subject, message and user_id of user it is being sent to.
// I've made it an easy to use function so you can adapt it to use in many situations on your site
// an example is in the welcome message system which is included with this package. The function
// also sends emails (if $send_email set) and does all the inbox checking stuff that normal pms do.
//
function iai_send_pm($user_to_id, $iai_subject, $iai_message, $send_email)
{
global $board_config, $lang, $db, $phpbb_root_path, $phpEx;

$sql = "SELECT *
FROM " . USERS_TABLE . "
WHERE user_id = " . $user_to_id . "
AND user_id <> " . ANONYMOUS;
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Tried obtaining data for a non-existent user', '', __LINE__, __FILE__, $sql);
}
$usertodata = $db->sql_fetchrow($result);

// prepare IAI message (IAI may have used html, smilies etc...)
$bbcode_uid = make_bbcode_uid();
$iai_message = str_replace("'", "''", $iai_message);

// This is to fix up some of the bad formatting which comes out of the AI
if(empty($iai_message))
{
$iai_message = "Thank you.";
}
$iai_message = prepare_message(trim($iai_message), 0, 1, 1, $bbcode_uid);

$msg_time = time();

// Do inbox limit stuff
$sql = "SELECT COUNT(privmsgs_id) AS inbox_items, MIN(privmsgs_date) AS oldest_post_time
FROM " . PRIVMSGS_TABLE . "
WHERE ( privmsgs_type = " . PRIVMSGS_NEW_MAIL . "
OR privmsgs_type = " . PRIVMSGS_READ_MAIL . "
OR privmsgs_type = " . PRIVMSGS_UNREAD_MAIL . " )
AND privmsgs_to_userid = " . $usertodata['user_id'];
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_MESSAGE, $lang['No_such_user']);
}

$sql_priority = ( SQL_LAYER == 'mysql' ) ? 'LOW_PRIORITY' : '';

if ( $inbox_info = $db->sql_fetchrow($result) )
{
if ( $inbox_info['inbox_items'] >= $board_config['max_inbox_privmsgs'] )
{
$sql = "DELETE $sql_priority FROM " . PRIVMSGS_TABLE . "
WHERE ( privmsgs_type = " . PRIVMSGS_NEW_MAIL . "
OR privmsgs_type = " . PRIVMSGS_READ_MAIL . "
OR privmsgs_type = " . PRIVMSGS_UNREAD_MAIL . " )
AND privmsgs_date = " . $inbox_info['oldest_post_time'] . "
AND privmsgs_to_userid = " . $usertodata['user_id'];
if ( !$db->sql_query($sql) )
{
message_die(GENERAL_ERROR, 'Could not delete your oldest privmsgs', '', __LINE__, __FILE__, $sql);
}
}
}

$sql_info = "INSERT INTO " . PRIVMSGS_TABLE . " (privmsgs_type, privmsgs_subject, privmsgs_from_userid, privmsgs_to_userid, privmsgs_date, privmsgs_ip, privmsgs_enable_html, privmsgs_enable_bbcode, privmsgs_enable_smilies, privmsgs_attach_sig)
VALUES (" . PRIVMSGS_NEW_MAIL . ", '" . str_replace("\'", "''", $iai_subject) . "', " . $board_config['iai_userid'] . ", " . $usertodata['user_id'] . ", $msg_time, '$user_ip', 0, 1, 1, 1)";

if ( !($result = $db->sql_query($sql_info, BEGIN_TRANSACTION)) )
{
message_die(GENERAL_ERROR, "Could not insert private message sent info.", "", __LINE__, __FILE__, $sql_info);
}

$privmsg_sent_id = $db->sql_nextid();

$sql = "INSERT INTO " . PRIVMSGS_TEXT_TABLE . " (privmsgs_text_id, privmsgs_bbcode_uid, privmsgs_text)
VALUES ($privmsg_sent_id, '" . $bbcode_uid . "', '" . str_replace("\'", "''", $iai_message) . "')";

if ( !$db->sql_query($sql, END_TRANSACTION) )
{
message_die(GENERAL_ERROR, "Could not insert/update private message sent text.", "", __LINE__, __FILE__, $sql_info);
}

// Add to the users new pm counter
$sql = "UPDATE " . USERS_TABLE . "
SET user_new_privmsg = user_new_privmsg + 1, user_last_privmsg = " . time() . "
WHERE user_id = " . $usertodata['user_id'];
if ( !$status = $db->sql_query($sql) )
{
message_die(GENERAL_ERROR, 'Could not update private message new/read status for user', '', __LINE__, __FILE__, $sql);
}

// now send email if all the usual conditions & $send_email is set
if ( $send_email && $usertodata['user_notify_pm'] && !empty($usertodata['user_email']) && $usertodata['user_active'] )
{
$email_headers = 'From: ' . $board_config['board_email'] . "\nReturn-Path: " . $board_config['board_email'] . "\r\n";

$script_name = preg_replace('/^\/?(.*?)\/?$/', "\\1", trim($board_config['script_path']));
$script_name = ( $script_name != '' ) ? $script_name . '/privmsg.'.$phpEx : 'privmsg.'.$phpEx;
$server_name = trim($board_config['server_name']);
$server_protocol = ( $board_config['cookie_secure'] ) ? 'https://' : 'http://';
$server_port = ( $board_config['server_port'] <> 80 ) ? ':' . trim($board_config['server_port']) . '/' : '/';

include($phpbb_root_path . 'includes/emailer.'.$phpEx);
$emailer = new emailer($board_config['smtp_delivery']);

$emailer->use_template('privmsg_notify', $usertodata['user_lang']);
$emailer->extra_headers($email_headers);
$emailer->email_address($usertodata['user_email']);
$emailer->set_subject(); //$lang['Notification_subject']

$emailer->assign_vars(array(
'USERNAME' => $usertodata['username'],
'SITENAME' => $board_config['sitename'],
'EMAIL_SIG' => str_replace('<br />', "\n", "-- \n" . $board_config['board_email_sig']),

'U_INBOX' => $server_protocol . $server_name . $server_port . $script_name . '?folder=inbox')
);

$emailer->send();
$emailer->reset();
}

return;
}

#
#-----[ OTWÓRZ ]------------------------------------------
#
privmsg.php

#
#-----[ ZNAJDŹ ]------------------------------------------
#
$template->assign_vars(array(
'META' => '<meta http-equiv="refresh" content="3;url=' . append_sid("privmsg.$phpEx?folder=inbox") . '">')
);

#
#-----[ DODAJ PRZED ]------------------------------------------
#
//
// START PM SYSTEM FOR IAI
//

// Should IAI respond to this pm?
if (
(
$mode != "edit"
)
&&
(
$to_userdata['user_id'] == $board_config['iai_userid']
)
&&
(
$board_config['iai_active_pm']
)
)
{

$iai_root_path = $phpbb_root_path . "mods/iai/";
include($iai_root_path . 'includes/iai_functions.'.$phpEx);

// Init IAI specific vars
$iai_subject = ( ( !preg_match('/^Re:/', $privmsg_subject) ) ? 'Re: ' : '' ) . $privmsg_subject;

// Get IAI reply
$user_id = ($userdata['session_logged_in']) ? $userdata['user_id'] : 0;
$topic_id = 0; // the null topic
$sesh_id = $userdata['session_id']; // should NOT be null in any situation
$numselects = 0;
// set bot to reply to subject as well as message as long as subject is not a reply (i.e. has Re: out the front)
$iai_reply_to = ( ( !preg_match('/^Re:/', $privmsg_subject) ) ? $privmsg_subject . " " : "" ) . $privmsg_message;
$iai_reply_to = str_replace("is " . $board_config['iai_username'], "are you", $iai_reply_to);
$iai_reply_to = str_replace($board_config['iai_username'], "you", $iai_reply_to);
$iai_reply = reply($iai_reply_to,$user_id,$topic_id,$sesh_id);
$iai_message = $iai_reply->response;

//
// START Delete user's message from bot's inbox/user's outbox (it gets too full and wastes space otherwise).
// Note that this wipes ALL PAST pms in the bot's inbox from the user. This ensures that any backlog of pms
// sent while bot was inactive are also wiped.
//
$sql = "UPDATE " . USERS_TABLE . "
SET user_unread_privmsg = user_unread_privmsg - 1
WHERE user_id = " . $board_config['iai_userid'];
if ( !$db->sql_query($sql) )
{
message_die(GENERAL_ERROR, 'Could not update private message read status for user', '', __LINE__, __FILE__, $sql);
}
$sql = "SELECT privmsgs_id
FROM " . PRIVMSGS_TABLE . "
WHERE privmsgs_to_userid = " . $board_config['iai_userid'] . " AND (privmsgs_type = " . PRIVMSGS_READ_MAIL . " OR privmsgs_type = " . PRIVMSGS_NEW_MAIL . " OR privmsgs_type = " . PRIVMSGS_UNREAD_MAIL . " )";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not obtain id list to delete all messages', '', __LINE__, __FILE__, $sql);
}
$mark_list = array();
while ( $row = $db->sql_fetchrow($result) )
{
$mark_list[] = $row['privmsgs_id'];
}
unset($delete_type);

if ( count($mark_list) )
{
$delete_sql_id = implode(', ', $mark_list);
}

$delete_text_sql = "DELETE FROM " . PRIVMSGS_TEXT_TABLE . "
WHERE privmsgs_text_id IN ($delete_sql_id)";
$delete_sql = "DELETE FROM " . PRIVMSGS_TABLE . "
WHERE privmsgs_id IN ($delete_sql_id)
AND privmsgs_to_userid = " . $board_config['iai_userid'] . "
AND (privmsgs_type = " . PRIVMSGS_READ_MAIL . " OR privmsgs_type = " . PRIVMSGS_NEW_MAIL . " OR privmsgs_type = " . PRIVMSGS_UNREAD_MAIL . " )";

if ( !$db->sql_query($delete_sql, BEGIN_TRANSACTION) )
{
message_die(GENERAL_ERROR, 'Could not delete private message info', '', __LINE__, __FILE__, $delete_sql);
}

if ( !$db->sql_query($delete_text_sql, END_TRANSACTION) )
{
message_die(GENERAL_ERROR, 'Could not delete private message text', '', __LINE__, __FILE__, $delete_text_sql);
}
//
// END delete sent pms
//

// run iai pm send function
$iai_message = str_replace(".", ". ", $iai_message);
$iai_message = str_replace("!", "! ", $iai_message);
$iai_message = str_replace("?", "? ", $iai_message);
iai_send_pm($userdata['user_id'], $iai_subject, $iai_message, 0);
}
//
// END PM SYSTEM FOR IAI
//

#
#-----[ OTWÓRZ ]------------------------------------------
#
includes/usercp_register.php

#
#-----[ ZNAJDŹ ]------------------------------------------
#
message_die(GENERAL_MESSAGE, $message);
} // if mode == register
}
} // End of submit

#
#-----[ DODAJ PRZED ]------------------------------------------
#
//
// START IAI welcome pm message
//
$iai_root_path = $phpbb_root_path . "mods/iai/";
include($iai_root_path.'includes/constants.'.$phpEx);
if($board_config['iai_active_wpm'])
{
$sql = "SELECT *
FROM " . IAI_BOT_T;
if(!$result = $db->sql_query($sql))
{
message_die(GENERAL_ERROR, "Could not query bot information", "", __LINE__, __FILE__, $sql);
}
else
{
while($row = $db->sql_fetchrow($result))
{
$bot_config[$row['name']] = $row['value'];
}
}

// Just a couple of replaces for better customisation on a per user basis
// no point making a special function since there are so few needed

$iai_wpm_subject = str_replace("[username]", $username, $bot_config['iai_wpm_subject']);
$iai_wpm_subject = str_replace("[user_id]", $user_id, $iai_wpm_subject);
$iai_wpm_subject = str_replace("[sitename]", $board_config['sitename'], $iai_wpm_subject);
$iai_wpm_subject = str_replace("[botname]", $bot_config['name'], $iai_wpm_subject);

$iai_wpm_message = str_replace("[username]", $username, $bot_config['iai_wpm_message']);
$iai_wpm_message = str_replace("[user_id]", $user_id, $iai_wpm_message);
$iai_wpm_message = str_replace("[sitename]", $board_config['sitename'], $iai_wpm_message);
$iai_wpm_message = str_replace("[botname]", $bot_config['name'], $iai_wpm_message);

// Will not send a pm notification via email (already sent the standard welcome email)
// Simply change the 0 to a 1 to turn it on
iai_send_pm($user_id, $iai_wpm_subject, $iai_wpm_message, 0);
}
//
// END IAI welcome pm message
//

#
#-----[ OTWÓRZ ]------------------------------------------
#
admin/modules_data.php

#
#-----[ ZNAJDŹ ]------------------------------------------
#
'Poll Admin' => array(
'Poll Results' => array("admin_voting.$phpEx", 55),
),

#
#-----[ DODAJ PRZED ]------------------------------------------
#
'Bot' => array(
'Konfiguracja' => array("admin_iai_ai.$phpEx", 666),
'Instalacja AIML' => array("admin_iai_aiml_install.$phpEx", 667),
'Opcji forum' => array("admin_iai_forum.$phpEx", 668),
'Opcje PW' => array("admin_iai_pm.$phpEx", 666),
),
#
#-----[ ZAPISZ/ZAMKNIJ WSZYSTKIE PLIKI ]------------------------------------------
#
##############################################################
## PO INSTALACJI:
## Powinieneś zmienić (phpbbb_root_dir)/bot/ to (phpbb_root_dir)/(nazwa_twojego_bota)/
## Instalacja plików AIML:
## o Aby uczynić swojego bota bardziej inteligentnym, Musisz użyć wejść w PA "Instalacja AIML"
## i użyć "Wyszyść mózg bota", następnym krokiem jest instalacja wszystkich plików z formularza (najlpierw ## wrzuć wszystkie pliki z tego RAR z katalogu "aiml files") do mods/iai/aiml).
##
## IF YOUR BOT SEEMS VERY STUPID THEN THE MOST LIKELY PROBLEM IS THAT YOU DO NOT HAVE
## ENOUGH
## AIML FILES INSTALLED TO YOUR BOTS BRAIN. ALWAYS TRY THIS FIRST.
##
##
## Strona twojego bota to (phpbb_root_dir)/mods/iai/index.html or
## (phpbb_root_dir)/(nazwa_twojego_bota)/index.html
##############################################################


IAI Bot.rar
Plik IAI Bot wraz z bazami AIML
Pobierz Plik ściągnięto 682 raz(y) 792,09 KB

Ostatnio zmieniony przez Ekskuator 07-11-2006, 21:19, w całości zmieniany 3 razy  
 
     
Gadatliwa Kasia 

   
Jezdziec


Pomógł: 32 razy
Posty: 439
Wysłany: 25-10-2006, 11:35   

A mozesz zrobić coś podobnego do Robocika, że bedzie sam Warny wstawiał. Mnie interesuje tylko taka wersja robocika, jesli można to możesz podesłac gotową paczke po polsku?
_________________
mamy prawo do błedu.. ale obowiązek do naprawienia go!
 
     
kactuzz

Posty: 14
Wysłany: 25-10-2006, 18:58   

No to ja poczekam, aż bocik będzie mogł dawać warny i będzie po Polsku :)
 
     
Ekskuator


Posty: 10
Wysłany: 25-10-2006, 19:11   

Właśnie pracuję nad warnami, a co do polskiej bazy to chyba będzię ją trzeba pisać od nowa pod forum (tam teraz jest z lingubota ALICE) i na początku po prostu będzie mała albo ukaże się późno.
 
     
Jezdziec


Pomógł: 32 razy
Posty: 439
Wysłany: 25-10-2006, 21:26   

A to poczekamy. Nie śpieszy mi sie, a mam pytanie: ile tak przypuszczalnie bedzue trwało to??
_________________
mamy prawo do błedu.. ale obowiązek do naprawienia go!
 
     
NineX



Pomógł: 546 razy
Posty: 1983
Wysłany: 31-10-2006, 16:35   

I co jest juz polski?
 
     
CMP


Pomógł: 27 razy
Posty: 241
Wysłany: 01-11-2006, 00:33   

ten bot odpowiada mi nad postem zamiast pod :evil: :evil:
_________________
-> http://chucktv.pl/ Polskie centrum fanów serialu Chuck
-> http://forum.chucktv.pl/
-> Jeśli chcesz mieć unikalny styl na swoim forum, napisz na PW, GG lub email.
-> Wykonuje instalacje, aktualizacje, wgrywanie modów i przeróbki stylów.
 
     
garbacz

Pomógł: 1 raz
Posty: 120
Wysłany: 01-11-2006, 00:56   

mam mały problem, a mianowicie, jak już z nim rozmawiam, to po którejś z jego odpowiedzi, następuje błąd.

Jak ja odpisuje to wypowiedz nie jest jako nowy post, tylko post ten zostaje dołączony do mojego stareo posty, czyli bot już nie odpisuje.

I dopiero jak zacznę od początku to jest ok, ale po kilky postach znów tosamo...

[ Dodano: 01-11-2006, 16:57 ]
No więc tak, wszystko zinstalowałem miałem tylko kłopoty z plikiem

includes/usercp_register.php

ale sobie poradziłem.
Może mam coś źle ustawione, ale jak piszę z tym botem, to jego wypowiedz (często ale nie zawsze) ukazuje się przed moim pytaniem !!
Tak jakby był szybszy odemnie, reszta jest ok!
Jak mogę to zmienić ?? Czy mogę go jakoś opuźnić ?? Żeby np, odpisywał 5 sekund po mnie ??
 
     
paniczow

Pomógł: 2 razy
Posty: 181
Wysłany: 01-11-2006, 17:03   

ja też mam problem z tym plikiem, tam nie ma tych linijek co są w instrukcji !!

Kod:
includes/usercp_register.php


Kod:
message_die(GENERAL_MESSAGE, $message);
} // if mode == register
}
} // End of submit


Daję w załączniku mój plik.

usercp_register.rar
Pobierz Plik ściągnięto 454 raz(y) 14,94 KB

 
     
Ekskuator


Posty: 10
Wysłany: 01-11-2006, 18:04   

Chwilowo niestety nie mam czasu zajmować się botem i zapomniałem usunąć niepotrzebny kod. Nie dodawajcie tego do usercp_register.php. Kolejna rzecz to na razie nie będę nic dodawał najwcześniej w niedzielę jestem w stanie coś zrobić przy bocie.
 
     
yasiu


Pomógł: 12 razy
Posty: 206
Wysłany: 14-11-2006, 18:45   

Data postu i data obietnicy o zajęciu się modem hmmm a on jest w gotowych?
 
     
paniczow

Pomógł: 2 razy
Posty: 181
Wysłany: 18-11-2006, 20:42   

jeszcze niestety nie, owy bot nie jest gotowy tzn instrukcja obsługi, ja mam zinstalowanego bota ale są błedy i nie wiem jak je naprawic... Modzik by się przydał nawet bardzo..
 
     
piterpl

Posty: 36
Wysłany: 24-11-2006, 13:59   

co z tą polską wersją??? modyfikacja bardzo fajna tylko trzeba bylo by polską wersje :p
_________________
pozdro [*you]
 
     
garbacz

Pomógł: 1 raz
Posty: 120
Wysłany: 29-11-2006, 17:12   

Ja wole oryginalną wersję językową, ale jak narazie instalacja nie jest poprawna, bo wystepują błedy...
 
     
Gadatliwa Kasia 

   
Nikikin


Posty: 12
Wysłany: 30-11-2006, 19:46   

Jak to dziala? On sobie wgrywa odpowiediz na pytanie do bazy? Czy bardzo obciaza serwer/baze ?
_________________
be polite and - SHUT THE F*CK UP
 
     
Wyświetl posty z ostatnich:   
Odpowiedz do tematu
Nie możesz pisać nowych tematów
Nie możesz odpowiadać w tematach
Nie możesz zmieniać swoich postów
Nie możesz usuwać swoich postów
Nie możesz głosować w ankietach
Nie możesz załączać plików na tym forum
Możesz ściągać załączniki na tym forum
Dodaj temat do Ulubionych
Wersja do druku

Skocz do:  

Kopiowanie wszelkich treści zawartych na forum, modyfikacji oraz instrukcji bez zgody administracji i autorów tematów/postów zabronione!

Powered by phpBB modified by Przemo © 2003 phpBB
Strona wygenerowana w 0,22 sekundy. Zapytań do SQL: 14
Polecane serwisy

Najlepsze oprogramowanie do prowadzenia sklepu internetowegoNajlepszy program do sklepu firmowany przez Przem'a

Sklep z gadżetami

serwis laptopów

phpbb

Polisy Ubezpieczeniowe TU Europa

Design Cart - Tworzenie sklepu internetowego

dnirozwoju.pl

Ranking Hostingów HostingOnline.pl

• Zamów reklamę