样式:AI回复增加显示思考中...

This commit is contained in:
xiao12feng8 2026-02-01 11:54:01 +08:00
parent 907ca22b60
commit 451906a9ac
5 changed files with 430 additions and 23 deletions

View File

@ -332,6 +332,16 @@ def _build_context_messages(
content = f"恋人发送了一张图片,内容是:{caption or '图片'}"
else:
content = msg.content
# 如果消息被编辑过添加特殊标记提醒AI
if msg.is_edited and msg.original_content:
if msg.role == "lover":
# AI的回复被用户纠正
content = f"[用户纠正] {content}\n(原回复:{msg.original_content}\n注意:用户认为原回复不准确,已纠正为上述内容,请以用户纠正的内容为准。"
else:
# 用户消息被编辑
content = f"{content}\n[已编辑,原内容:{msg.original_content}]"
messages.append({"role": role, "content": content})
return _trim_context_messages(messages)

View File

@ -83,7 +83,9 @@
@pause="onVideoPause(item.id)" @longpress="onVideoLongPress(item)"></video>
</view>
<!-- 普通文本消息 -->
<view v-else class="message-text">{{ item.content }}</view>
<view v-else class="message-text" :class="{ 'thinking-text': item.isThinking }">
{{ item.content }}
</view>
<!-- 语音容器独立存在仅对lover角色显示 -->
<view
@ -353,6 +355,8 @@
editingMessage: null,
baseURL: 'http://127.0.0.1:8080',
baseURLPy: 'http://127.0.0.1:8000',
//
messageSentTime: 0, //
}
},
onLoad() {
@ -535,28 +539,48 @@
sessionSend() {
SessionSend(this.form).then(res => {
if (res.code == 1) {
uni.showToast({
title: '发送成功',
icon: 'none',
position: 'top'
})
this.addBond()
this.form.message = '';
this.form.session_id = '';
this.$refs.aiRef.renderText = ''
this.$refs.aiRef.resultTextTemp = ''
this.$refs.aiRef.renderText = ''
// AI
//
this.refreshSessionData(true); //
//
const elapsedTime = Date.now() - this.messageSentTime;
const minThinkingTime = 5000; // 5
const remainingTime = Math.max(0, minThinkingTime - elapsedTime);
// 5
setTimeout(() => {
uni.showToast({
title: '发送成功',
icon: 'none',
position: 'top'
});
this.addBond();
this.form.message = '';
this.form.session_id = '';
this.$refs.aiRef.renderText = '';
this.$refs.aiRef.resultTextTemp = '';
this.$refs.aiRef.renderText = '';
// AI
this.refreshSessionData(true);
}, remainingTime);
} else {
//
this.sessionInitList.messages = this.sessionInitList.messages.filter(
msg => !msg.isThinking
);
uni.showToast({
title: res.msg,
icon: 'none',
position: 'top'
})
});
}
})
}).catch(err => {
//
this.sessionInitList.messages = this.sessionInitList.messages.filter(
msg => !msg.isThinking
);
uni.showToast({
title: '发送失败',
icon: 'none'
});
});
},
chatMessagesTts() {
ChatMessagesTts(this.chatMessagesTtsform.id).then(res => {
@ -859,8 +883,27 @@
return;
}
uni.showLoading({
title: '发送中...'
//
this.messageSentTime = Date.now();
// ""
const thinkingMessage = {
id: 'thinking_' + Date.now(),
role: 'lover',
content: '思考中...',
isThinking: true, //
created_at: new Date().toISOString()
};
//
if (!this.sessionInitList.messages) {
this.sessionInitList.messages = [];
}
this.sessionInitList.messages.push(thinkingMessage);
//
this.$nextTick(() => {
this.scrollToBottom();
});
this.addBondform.type = 1;
@ -2052,6 +2095,22 @@
word-break: break-all;
}
/* 思考中状态的文本样式 */
.thinking-text {
color: #999 !important;
font-style: italic;
animation: thinking-pulse 1.5s ease-in-out infinite;
}
@keyframes thinking-pulse {
0%, 100% {
opacity: 0.5;
}
50% {
opacity: 1;
}
}
.message-image {
max-width: 200rpx;
max-height: 200rpx;

View File

@ -16898,3 +16898,339 @@ T File
[ sql ] [ SQL ] SELECT SUM(intimacy) AS tp_sum FROM `nf_user_bond_log` WHERE `user_id` = 70 AND `createdate` = '2026-02-01' LIMIT 1 [ RunTime:0.000564s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_third` [ RunTime:0.001462s ]
[ sql ] [ SQL ] SELECT `openid` FROM `nf_third` WHERE `user_id` = 70 AND `platform` = 'wxapp' LIMIT 1 [ RunTime:0.000546s ]
---------------------------------------------------------------
[ 2026-02-01T11:51:54+08:00 ] 127.0.0.1 GET 127.0.0.1:8080/api/user_basic/get_user_basic
[运行时间0.141074s] [吞吐率7.09req/s] [内存消耗4,272.90kb] [文件加载92]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.000029s ]
[ info ] [ CACHE ] INIT File
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @app_init [ RunTime:0.005641s ]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.005696s ]
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_init [ RunTime:0.001755s ]
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\thinkphp\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_dispatch [ RunTime:0.000042s ]
[ info ] [ ROUTE ] array (
'type' => 'module',
'module' =>
array (
0 => 'api',
1 => 'user_basic',
2 => 'get_user_basic',
),
)
[ info ] [ HEADER ] array (
'token' => '2ea3606b-6fca-4ede-9151-41b8c50a3207',
'connection' => 'keep-alive',
'accept' => '*/*',
'accept-encoding' => 'gzip, deflate, zstd',
'user-agent' => 'python-requests/2.32.5',
'host' => '127.0.0.1:8080',
'content-length' => '',
'content-type' => '',
)
[ info ] [ PARAM ] array (
)
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\public/../application/api\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @module_init [ RunTime:0.002643s ]
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @module_init [ RunTime:0.000693s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @module_init [ RunTime:0.000534s ]
[ info ] [ TOKEN ] INIT Mysql
[ info ] [ DB ] INIT mysql
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @upload_config_init [ RunTime:0.001218s ]
[ info ] [ BEHAVIOR ] Run \addons\epay\Epay @action_begin [ RunTime:0.003093s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @action_begin [ RunTime:0.000082s ]
[ info ] [ RUN ] app\api\controller\UserBasic->get_user_basic[ C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\application\api\controller\UserBasic.php ]
[ info ] [ LOG ] INIT File
[ sql ] [ DB ] CONNECT:[ UseTime:0.002726s ] mysql:host=127.0.0.1;port=3306;dbname=fastadmin;charset=utf8mb4
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_token` [ RunTime:0.002247s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.000561s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user` [ RunTime:0.003677s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user` WHERE `id` = 70 LIMIT 1 [ RunTime:0.000931s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.001028s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_level` [ RunTime:0.002358s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_level` WHERE `level` = '3' LIMIT 1 [ RunTime:0.000630s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_config` [ RunTime:0.002189s ]
[ sql ] [ SQL ] SELECT SUM(upper) AS tp_sum FROM `nf_user_bond_config` LIMIT 1 [ RunTime:0.000536s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_log` [ RunTime:0.002134s ]
[ sql ] [ SQL ] SELECT SUM(intimacy) AS tp_sum FROM `nf_user_bond_log` WHERE `user_id` = 70 AND `createdate` = '2026-02-01' LIMIT 1 [ RunTime:0.000654s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_third` [ RunTime:0.002065s ]
[ sql ] [ SQL ] SELECT `openid` FROM `nf_third` WHERE `user_id` = 70 AND `platform` = 'wxapp' LIMIT 1 [ RunTime:0.000677s ]
---------------------------------------------------------------
[ 2026-02-01T11:51:54+08:00 ] 127.0.0.1 GET 127.0.0.1:8080/api/user_basic/get_user_basic
[运行时间0.187604s] [吞吐率5.33req/s] [内存消耗4,272.90kb] [文件加载92]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.000038s ]
[ info ] [ CACHE ] INIT File
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @app_init [ RunTime:0.005781s ]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.005835s ]
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_init [ RunTime:0.001643s ]
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\thinkphp\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_dispatch [ RunTime:0.000040s ]
[ info ] [ ROUTE ] array (
'type' => 'module',
'module' =>
array (
0 => 'api',
1 => 'user_basic',
2 => 'get_user_basic',
),
)
[ info ] [ HEADER ] array (
'token' => '2ea3606b-6fca-4ede-9151-41b8c50a3207',
'connection' => 'keep-alive',
'accept' => '*/*',
'accept-encoding' => 'gzip, deflate, zstd',
'user-agent' => 'python-requests/2.32.5',
'host' => '127.0.0.1:8080',
'content-length' => '',
'content-type' => '',
)
[ info ] [ PARAM ] array (
)
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\public/../application/api\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @module_init [ RunTime:0.005641s ]
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @module_init [ RunTime:0.009896s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @module_init [ RunTime:0.000654s ]
[ info ] [ TOKEN ] INIT Mysql
[ info ] [ DB ] INIT mysql
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @upload_config_init [ RunTime:0.001152s ]
[ info ] [ BEHAVIOR ] Run \addons\epay\Epay @action_begin [ RunTime:0.002564s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @action_begin [ RunTime:0.000066s ]
[ info ] [ RUN ] app\api\controller\UserBasic->get_user_basic[ C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\application\api\controller\UserBasic.php ]
[ info ] [ LOG ] INIT File
[ sql ] [ DB ] CONNECT:[ UseTime:0.004184s ] mysql:host=127.0.0.1;port=3306;dbname=fastadmin;charset=utf8mb4
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_token` [ RunTime:0.002205s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.000579s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user` [ RunTime:0.003425s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user` WHERE `id` = 70 LIMIT 1 [ RunTime:0.000858s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.000894s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_level` [ RunTime:0.002730s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_level` WHERE `level` = '3' LIMIT 1 [ RunTime:0.000712s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_config` [ RunTime:0.002673s ]
[ sql ] [ SQL ] SELECT SUM(upper) AS tp_sum FROM `nf_user_bond_config` LIMIT 1 [ RunTime:0.000619s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_log` [ RunTime:0.002269s ]
[ sql ] [ SQL ] SELECT SUM(intimacy) AS tp_sum FROM `nf_user_bond_log` WHERE `user_id` = 70 AND `createdate` = '2026-02-01' LIMIT 1 [ RunTime:0.000818s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_third` [ RunTime:0.002579s ]
[ sql ] [ SQL ] SELECT `openid` FROM `nf_third` WHERE `user_id` = 70 AND `platform` = 'wxapp' LIMIT 1 [ RunTime:0.000742s ]
---------------------------------------------------------------
[ 2026-02-01T11:52:04+08:00 ] 127.0.0.1 GET 127.0.0.1:8080/api/user_basic/get_user_basic
[运行时间0.209735s] [吞吐率4.77req/s] [内存消耗4,272.90kb] [文件加载92]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.000033s ]
[ info ] [ CACHE ] INIT File
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @app_init [ RunTime:0.005654s ]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.005707s ]
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_init [ RunTime:0.001637s ]
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\thinkphp\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_dispatch [ RunTime:0.000036s ]
[ info ] [ ROUTE ] array (
'type' => 'module',
'module' =>
array (
0 => 'api',
1 => 'user_basic',
2 => 'get_user_basic',
),
)
[ info ] [ HEADER ] array (
'token' => '2ea3606b-6fca-4ede-9151-41b8c50a3207',
'connection' => 'keep-alive',
'accept' => '*/*',
'accept-encoding' => 'gzip, deflate, zstd',
'user-agent' => 'python-requests/2.32.5',
'host' => '127.0.0.1:8080',
'content-length' => '',
'content-type' => '',
)
[ info ] [ PARAM ] array (
)
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\public/../application/api\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @module_init [ RunTime:0.002667s ]
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @module_init [ RunTime:0.000722s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @module_init [ RunTime:0.000570s ]
[ info ] [ TOKEN ] INIT Mysql
[ info ] [ DB ] INIT mysql
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @upload_config_init [ RunTime:0.001202s ]
[ info ] [ BEHAVIOR ] Run \addons\epay\Epay @action_begin [ RunTime:0.003355s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @action_begin [ RunTime:0.000074s ]
[ info ] [ RUN ] app\api\controller\UserBasic->get_user_basic[ C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\application\api\controller\UserBasic.php ]
[ info ] [ LOG ] INIT File
[ sql ] [ DB ] CONNECT:[ UseTime:0.002125s ] mysql:host=127.0.0.1;port=3306;dbname=fastadmin;charset=utf8mb4
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_token` [ RunTime:0.002584s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.000680s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user` [ RunTime:0.003801s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user` WHERE `id` = 70 LIMIT 1 [ RunTime:0.000886s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.000865s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_level` [ RunTime:0.002903s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_level` WHERE `level` = '3' LIMIT 1 [ RunTime:0.000855s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_config` [ RunTime:0.004169s ]
[ sql ] [ SQL ] SELECT SUM(upper) AS tp_sum FROM `nf_user_bond_config` LIMIT 1 [ RunTime:0.000679s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_log` [ RunTime:0.002971s ]
[ sql ] [ SQL ] SELECT SUM(intimacy) AS tp_sum FROM `nf_user_bond_log` WHERE `user_id` = 70 AND `createdate` = '2026-02-01' LIMIT 1 [ RunTime:0.001045s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_third` [ RunTime:0.002740s ]
[ sql ] [ SQL ] SELECT `openid` FROM `nf_third` WHERE `user_id` = 70 AND `platform` = 'wxapp' LIMIT 1 [ RunTime:0.001212s ]
---------------------------------------------------------------
[ 2026-02-01T11:52:04+08:00 ] 127.0.0.1 GET 127.0.0.1:8080/api/user_basic/get_user_basic
[运行时间0.250969s] [吞吐率3.98req/s] [内存消耗4,272.90kb] [文件加载92]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.000033s ]
[ info ] [ CACHE ] INIT File
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @app_init [ RunTime:0.005076s ]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.005137s ]
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_init [ RunTime:0.001825s ]
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\thinkphp\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_dispatch [ RunTime:0.000051s ]
[ info ] [ ROUTE ] array (
'type' => 'module',
'module' =>
array (
0 => 'api',
1 => 'user_basic',
2 => 'get_user_basic',
),
)
[ info ] [ HEADER ] array (
'token' => '2ea3606b-6fca-4ede-9151-41b8c50a3207',
'connection' => 'keep-alive',
'accept' => '*/*',
'accept-encoding' => 'gzip, deflate, zstd',
'user-agent' => 'python-requests/2.32.5',
'host' => '127.0.0.1:8080',
'content-length' => '',
'content-type' => '',
)
[ info ] [ PARAM ] array (
)
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\public/../application/api\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @module_init [ RunTime:0.014400s ]
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @module_init [ RunTime:0.001760s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @module_init [ RunTime:0.001239s ]
[ info ] [ TOKEN ] INIT Mysql
[ info ] [ DB ] INIT mysql
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @upload_config_init [ RunTime:0.001307s ]
[ info ] [ BEHAVIOR ] Run \addons\epay\Epay @action_begin [ RunTime:0.003118s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @action_begin [ RunTime:0.000101s ]
[ info ] [ RUN ] app\api\controller\UserBasic->get_user_basic[ C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\application\api\controller\UserBasic.php ]
[ info ] [ LOG ] INIT File
[ sql ] [ DB ] CONNECT:[ UseTime:0.001683s ] mysql:host=127.0.0.1;port=3306;dbname=fastadmin;charset=utf8mb4
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_token` [ RunTime:0.002625s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.000717s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user` [ RunTime:0.004278s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user` WHERE `id` = 70 LIMIT 1 [ RunTime:0.001040s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.001101s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_level` [ RunTime:0.002503s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_level` WHERE `level` = '3' LIMIT 1 [ RunTime:0.000617s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_config` [ RunTime:0.002297s ]
[ sql ] [ SQL ] SELECT SUM(upper) AS tp_sum FROM `nf_user_bond_config` LIMIT 1 [ RunTime:0.000646s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_log` [ RunTime:0.002044s ]
[ sql ] [ SQL ] SELECT SUM(intimacy) AS tp_sum FROM `nf_user_bond_log` WHERE `user_id` = 70 AND `createdate` = '2026-02-01' LIMIT 1 [ RunTime:0.000688s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_third` [ RunTime:0.002470s ]
[ sql ] [ SQL ] SELECT `openid` FROM `nf_third` WHERE `user_id` = 70 AND `platform` = 'wxapp' LIMIT 1 [ RunTime:0.000706s ]
---------------------------------------------------------------
[ 2026-02-01T11:52:12+08:00 ] 127.0.0.1 GET 127.0.0.1:8080/api/user_basic/get_user_basic
[运行时间0.089233s] [吞吐率11.21req/s] [内存消耗4,272.90kb] [文件加载92]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.000021s ]
[ info ] [ CACHE ] INIT File
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @app_init [ RunTime:0.003574s ]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.003613s ]
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_init [ RunTime:0.000929s ]
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\thinkphp\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_dispatch [ RunTime:0.000026s ]
[ info ] [ ROUTE ] array (
'type' => 'module',
'module' =>
array (
0 => 'api',
1 => 'user_basic',
2 => 'get_user_basic',
),
)
[ info ] [ HEADER ] array (
'token' => '2ea3606b-6fca-4ede-9151-41b8c50a3207',
'connection' => 'keep-alive',
'accept' => '*/*',
'accept-encoding' => 'gzip, deflate, zstd',
'user-agent' => 'python-requests/2.32.5',
'host' => '127.0.0.1:8080',
'content-length' => '',
'content-type' => '',
)
[ info ] [ PARAM ] array (
)
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\public/../application/api\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @module_init [ RunTime:0.001651s ]
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @module_init [ RunTime:0.000416s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @module_init [ RunTime:0.000508s ]
[ info ] [ TOKEN ] INIT Mysql
[ info ] [ DB ] INIT mysql
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @upload_config_init [ RunTime:0.001061s ]
[ info ] [ BEHAVIOR ] Run \addons\epay\Epay @action_begin [ RunTime:0.002854s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @action_begin [ RunTime:0.000081s ]
[ info ] [ RUN ] app\api\controller\UserBasic->get_user_basic[ C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\application\api\controller\UserBasic.php ]
[ info ] [ LOG ] INIT File
[ sql ] [ DB ] CONNECT:[ UseTime:0.001339s ] mysql:host=127.0.0.1;port=3306;dbname=fastadmin;charset=utf8mb4
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_token` [ RunTime:0.001722s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.000678s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user` [ RunTime:0.002661s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user` WHERE `id` = 70 LIMIT 1 [ RunTime:0.000810s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.000552s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_level` [ RunTime:0.001680s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_level` WHERE `level` = '3' LIMIT 1 [ RunTime:0.000598s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_config` [ RunTime:0.002090s ]
[ sql ] [ SQL ] SELECT SUM(upper) AS tp_sum FROM `nf_user_bond_config` LIMIT 1 [ RunTime:0.000522s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_log` [ RunTime:0.002085s ]
[ sql ] [ SQL ] SELECT SUM(intimacy) AS tp_sum FROM `nf_user_bond_log` WHERE `user_id` = 70 AND `createdate` = '2026-02-01' LIMIT 1 [ RunTime:0.000597s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_third` [ RunTime:0.001572s ]
[ sql ] [ SQL ] SELECT `openid` FROM `nf_third` WHERE `user_id` = 70 AND `platform` = 'wxapp' LIMIT 1 [ RunTime:0.000571s ]
---------------------------------------------------------------
[ 2026-02-01T11:52:12+08:00 ] 127.0.0.1 GET 127.0.0.1:8080/api/user_basic/get_user_basic
[运行时间0.093693s] [吞吐率10.67req/s] [内存消耗4,272.90kb] [文件加载92]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.000025s ]
[ info ] [ CACHE ] INIT File
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @app_init [ RunTime:0.003575s ]
[ info ] [ BEHAVIOR ] Run Closure @app_init [ RunTime:0.003617s ]
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_init [ RunTime:0.000891s ]
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\thinkphp\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @app_dispatch [ RunTime:0.000026s ]
[ info ] [ ROUTE ] array (
'type' => 'module',
'module' =>
array (
0 => 'api',
1 => 'user_basic',
2 => 'get_user_basic',
),
)
[ info ] [ HEADER ] array (
'token' => '2ea3606b-6fca-4ede-9151-41b8c50a3207',
'connection' => 'keep-alive',
'accept' => '*/*',
'accept-encoding' => 'gzip, deflate, zstd',
'user-agent' => 'python-requests/2.32.5',
'host' => '127.0.0.1:8080',
'content-length' => '',
'content-type' => '',
)
[ info ] [ PARAM ] array (
)
[ info ] [ LANG ] C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\public/../application/api\lang\zh-cn.php
[ info ] [ BEHAVIOR ] Run app\common\behavior\Common @module_init [ RunTime:0.001518s ]
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @module_init [ RunTime:0.000426s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @module_init [ RunTime:0.000371s ]
[ info ] [ TOKEN ] INIT Mysql
[ info ] [ DB ] INIT mysql
[ info ] [ BEHAVIOR ] Run \addons\alioss\Alioss @upload_config_init [ RunTime:0.000696s ]
[ info ] [ BEHAVIOR ] Run \addons\epay\Epay @action_begin [ RunTime:0.001869s ]
[ info ] [ BEHAVIOR ] Run \addons\third\Third @action_begin [ RunTime:0.000073s ]
[ info ] [ RUN ] app\api\controller\UserBasic->get_user_basic[ C:\Users\Administrator\Desktop\Project\AI_GirlFriend\xunifriend_RaeeC\application\api\controller\UserBasic.php ]
[ info ] [ LOG ] INIT File
[ sql ] [ DB ] CONNECT:[ UseTime:0.012236s ] mysql:host=127.0.0.1;port=3306;dbname=fastadmin;charset=utf8mb4
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_token` [ RunTime:0.001749s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.000592s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user` [ RunTime:0.003644s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user` WHERE `id` = 70 LIMIT 1 [ RunTime:0.000726s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_token` WHERE `token` = 'add92c4de35c0dd27585fa5979c6db3b7834766e' LIMIT 1 [ RunTime:0.000571s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_level` [ RunTime:0.001940s ]
[ sql ] [ SQL ] SELECT * FROM `nf_user_level` WHERE `level` = '3' LIMIT 1 [ RunTime:0.000661s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_config` [ RunTime:0.001567s ]
[ sql ] [ SQL ] SELECT SUM(upper) AS tp_sum FROM `nf_user_bond_config` LIMIT 1 [ RunTime:0.000474s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_user_bond_log` [ RunTime:0.001486s ]
[ sql ] [ SQL ] SELECT SUM(intimacy) AS tp_sum FROM `nf_user_bond_log` WHERE `user_id` = 70 AND `createdate` = '2026-02-01' LIMIT 1 [ RunTime:0.000544s ]
[ sql ] [ SQL ] SHOW COLUMNS FROM `nf_third` [ RunTime:0.001700s ]
[ sql ] [ SQL ] SELECT `openid` FROM `nf_third` WHERE `user_id` = 70 AND `platform` = 'wxapp' LIMIT 1 [ RunTime:0.000734s ]

View File

@ -1,6 +1,8 @@
1. 将密码校验删除,因为无法生成模型,用最简单的方法来尝试这些内容。
2. 将Hbuilder的AppId更换成自己的原本的保留(__UNI__1F3C178)。还是无法正常编译将下面的插件注释掉不用Agora-RTC音视频插件和AudioRecode录音插件。
3. 增加tab栏但是还没有加上对应的功能
4. 增加聊天背景选择功能,会员可以自定义背景
5. 增加恋人消息编辑功能,更新**数据库**,加上一些编辑消息、编辑时间相关字段。用户编辑消息之后恋人不回答,只会更新记忆和摘要的数据库,下一次回答的时候会重新引用这个更新后的记忆。
6. lian
- [ ] 增加tab栏但是还没有加上对应的功能
3. 增加聊天背景选择功能,会员可以自定义背景
4. 增加恋人消息编辑功能,更新**数据库**,加上一些编辑消息、编辑时间相关字段。用户编辑消息之后恋人不回答,只会更新记忆和摘要的数据库,下一次回答的时候会重新引用这个更新后的记忆。
- [ ] 礼物、换装、音色样式更改,但是还未更新数据库
5. 恋人消息回复增加思考中...
6.