fixed
This commit is contained in:
@@ -86,12 +86,14 @@ class Reporttt
|
|||||||
Db::table('fa_tt_userbaseinfo')
|
Db::table('fa_tt_userbaseinfo')
|
||||||
->insert($basedata);
|
->insert($basedata);
|
||||||
|
|
||||||
$content = [
|
$contentstr = input('content');
|
||||||
//["role" => "user", "content" => '']
|
if(empty($contentstr)){
|
||||||
];
|
return json(Tools::set_fail('content必须'));
|
||||||
foreach ($his_record as $item){
|
|
||||||
$content[] = ["role" => "user", "content" => $item['chat_msg']];
|
|
||||||
}
|
}
|
||||||
|
$content = json_decode($contentstr,true);
|
||||||
|
//foreach ($his_record as $item){
|
||||||
|
// $content[] = ["role" => "user", "content" => $item['chat_msg']];
|
||||||
|
//}
|
||||||
$chatobj->setBefore($content);
|
$chatobj->setBefore($content);
|
||||||
|
|
||||||
$chatobj->chat($question,$config,$answer_json_arr);
|
$chatobj->chat($question,$config,$answer_json_arr);
|
||||||
|
|||||||
Reference in New Issue
Block a user