Skip to content

feat: 对 BEFORE_MESSAGE_UPDATE 提供更多楼层信息 - #209

Open
StageDog wants to merge 1 commit into
betafrom
feat/more_context_before_message_update
Open

feat: 对 BEFORE_MESSAGE_UPDATE 提供更多楼层信息#209
StageDog wants to merge 1 commit into
betafrom
feat/more_context_before_message_update

Conversation

@StageDog

@StageDog StageDog commented Jul 12, 2026

Copy link
Copy Markdown
Collaborator

BEFORE_MESSAGE_UPDATE 事件额外提供 message_id 和 swipe_id 便于判断某个楼层更新完成
但是开场白是不是不一定触发这个(


相关:https://discord.com/channels/1134557553011998840/1400321862235328552/1525581198036832407

@github-actions

Copy link
Copy Markdown
Contributor

🔍 PR Test Report

🧪 Test Results

✅ All tests passed!

Type Passed Failed Total
Test Suites 17 0 17
Tests 407 0 407

📊 Coverage Report

Metric Coverage Details
Lines 65.04% 1293/1988
Statements 64.67% 1320/2041
Functions 65.15% 144/221
Branches 63.14% 651/1031

Coverage Thresholds

  • ✅ Lines: 65.04% (Passed, threshold: 50%)
  • ✅ Statements: 64.67% (Passed, threshold: 50%)
  • ✅ Functions: 65.15% (Passed, threshold: 50%)
  • ✅ Branches: 63.14% (Passed, threshold: 50%)

Generated at 2026-07-12T11:46:26.854Z

@MagicalAstrogy

Copy link
Copy Markdown
Owner

LGFM

@MagicalAstrogy

Copy link
Copy Markdown
Owner

哦不对,getChatMessages返回的楼层不一定是 message_id

if (!_.has(variables, 'stat_data')) {
return;
}
const swipe_id = SillyTavern.chat[message_id]?.swipe_id??0;

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

可能要拿chat_message 里面的

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

没看懂,你改(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants