Commit graph

325 commits

Author SHA1 Message Date
xmanrui
38096d1589 test: wait for update service shutdown before restart 2026-08-31 20:30:48 +08:00
xiemanR
7a16718922
Merge pull request #101 from evanfang0054/feat/feishu-topic-session-isolation
feat(feishu): isolate Harness sessions per topic in topic groups
2026-08-31 20:08:45 +08:00
evanfang0054
fd6e0af81b feat(feishu): thread command replies, cards, and approvals to the triggering message
Plain command replies (menu cards, session/workspace/watch lists, /new,
/status, /compact, /archived, model and preset commands) and Harness
approval prompts were sent as fresh messages keyed only by chat_id, so
in topic groups they landed in the group's default area instead of the
topic the conversation belongs to.

Deliver them as replies to the triggering message, mirroring how stream
answers already thread:

- #sendCard accepts { replyTo } and replies interactively, falling back
  to a plain card when the referenced message is gone
- command replies, status text, menu/session/workspace/watch cards,
  approval prompts and resolved-question notices all carry the
  triggering message id
- batch-input failure notices follow the same rule

- bridge.test.mjs: /new in a topic group must thread the confirmation
  text and the menu card to the command message
- lib/index.js: regenerated host bundle
2026-08-31 20:06:04 +08:00
evanfang0054
3b810fea6b fix(feishu): present Harness questions as threaded replies in topic groups
Regular answers reuse the stream card, which is created through the
reply API targeting the triggering message, so they land in the right
Feishu thread. Pending Harness questions (ask_user_question) were sent
through a fresh message.create with only the chat_id, so in topic
groups they appeared in the group's default area instead of the topic
the conversation belongs to.

Thread question delivery the same way as answers:

- #send accepts { replyTo } and uses im.v1.message.reply, falling back
  to a plain message when the referenced one is gone
- the triggering message id now travels into the interaction context
  and pending state, and #presentInteraction replies to it
- resolved-question notices reply to the user's answer message

- bridge.test.mjs: assert the question is delivered via the reply API
  targeting the triggering message inside a topic group
- lib/index.js: regenerated host bundle
2026-08-31 17:12:55 +08:00
xmanrui
1ce922933f update docs 2026-08-31 16:28:09 +08:00
evanfang0054
da4114dfe3 feat(feishu): isolate Harness sessions per topic in topic groups
conversationKey derived the group session key from chat_id alone, so in
Feishu topic groups every topic shared one Harness session: context,
/new, pending approvals, and batch-input state all leaked across topics.

Append the event's thread_id to the session key when present. Topic
groups stamp every message with a thread_id, so each topic now maps to
its own group:<chat_id>🧵<thread_id> session. Regular group chats
carry no thread_id and keep the single shared group:<chat_id> key; p2p
keys are untouched.

- message-utils.mjs: thread-aware conversationKey
- message-utils.test.mjs: topic isolation + regular-group fallback cases
- lib/index.js: regenerated host bundle
2026-08-31 13:54:35 +08:00
xiemanR
5ac63dd26b
Merge pull request #97 from Diluka/feat/qq-parse-face-tags
feat(qq): parse inbound QQ face/emoji tags into readable text
2026-08-31 10:02:46 +08:00
Diluka
5efcfa6725 feat(qq): parse inbound QQ face/emoji tags into readable text
QQ delivers emoji messages as opaque <faceType=..,faceId="..",ext="..">
markup fragments (the ext field holds a base64 JSON blob with the face
name, e.g. {"text":"吃瓜"}). Without translation, the Harness receives
only this unusable tag and loses what the sender actually meant.

Register the SDK's contentSanitizer({ parseFaceTags: true }) middleware,
mirroring tencent-connect/dsh-qqbot, so C2C and group inbound messages
surface as e.g. 【表情: 吃瓜】 instead of the raw tag.

- qq-runtime.mjs: register contentSanitizer before the typing indicator
- runtime.test.mjs: assert sanitizer registration and update middleware order
- lib/index.js: regenerated host bundle
2026-08-31 09:07:55 +08:00
xmanrui
a0845a7a25 chore: release v4.2.1 2026-08-31 03:33:15 +08:00
xmanrui
14519060f0 fix(telegram): isolate long polling transport 2026-08-31 03:31:07 +08:00
xmanrui
02ddea0054 chore: release v4.2.0 2026-08-31 01:38:31 +08:00
xiemanR
15c6bd2a45
Merge pull request #94 from C3H3-AI/feat/feishu-slash-commands
feat(feishu): 启动时注册飞书原生 Slash Command 命令面板
2026-08-31 01:22:08 +08:00
xmanrui
347acceffb fix(feishu): integrate slash command permissions 2026-08-31 01:21:38 +08:00
xmanrui
29aa138b3b Merge remote-tracking branch 'origin/main' into codex/pr94-updated
# Conflicts:
#	CHANGELOG.md
2026-08-31 01:21:34 +08:00
xmanrui
4496c9601e chore: release v4.1.1 2026-08-31 00:50:07 +08:00
xmanrui
4d18cc4de0 fix(qq): respond to all mentioned group members 2026-08-31 00:45:59 +08:00
C3H3-AI
64ba1463a8 feat(feishu): register native Slash Command panel on startup
The Feishu bot now calls the app_slash_commands OpenAPI at startup to register its common commands (menu, new, help, status, compact, sessionlist, workspacelist, watch, unwatch, watchlist, archived) as native Slash Commands, so typing / in a Feishu direct-message input box pops the command panel and tapping a command triggers it.

The command list is owned and pushed by dsh-im; it does not depend on the dsh/Harness backend. Registration is best-effort and runs asynchronously, so it never blocks the long-connection startup or message delivery when the app lacks the application:app_slash_command:read/write scopes.

Adds src/channels/feishu/slash-command-registry.mjs (manifest, list/create/delete, idempotent sync), wires it into feishu-runtime.mjs (slashCommands config flag + status fields), and covers it with tests.
2026-08-30 23:40:59 +08:00
xmanrui
7f968ac1d8 update docs 2026-08-30 18:16:52 +08:00
xmanrui
e08c3e9576 chore: release v4.1.0 2026-08-30 13:08:14 +08:00
xmanrui
32c6d48857 refine bot delivery settings labels 2026-08-30 13:03:57 +08:00
xmanrui
b90cb805c7 feat: add proactive delivery HTTP endpoint 2026-08-30 11:52:01 +08:00
xmanrui
31792d7bc8 feat: add stable proactive delivery 2026-08-30 11:24:53 +08:00
xmanrui
410cb822d7 docs: add project development retrospective 2026-08-30 08:38:21 +08:00
xmanrui
854d8873d7 docs: add implementation plans for open issues 2026-08-30 08:38:06 +08:00
xmanrui
c4fd59e086 revert: remove package contributor metadata 2026-08-30 08:35:31 +08:00
xiemanR
98da9a2f24
Merge pull request #91 from lKolabrodl/feat/session-preset-aliases
feat: add /sessions and /presets aliases
2026-08-30 08:31:57 +08:00
xmanrui
f47c7c79fa chore: credit PR contributor 2026-08-30 08:30:13 +08:00
xmanrui
ff2f096c59 update docs 2026-08-30 08:24:36 +08:00
MikhailB
98c1e48271 feat: add session and preset list aliases 2026-08-30 02:34:40 +03:00
xmanrui
92ec91b7bd chore: release v4.0.1 2026-08-30 07:02:50 +08:00
xmanrui
8794a46e81 chore: release v4.0.0 2026-08-29 20:26:00 +08:00
xmanrui
6b9118fe95 fix: support legacy and current DSH hosts 2026-08-29 20:22:07 +08:00
xmanrui
72ffd7115c chore: release v3.2.0 2026-08-29 10:49:19 +08:00
xmanrui
0cb79f74e9 feat: add message source context enhancement 2026-08-29 10:46:06 +08:00
xmanrui
5928b33057 fix(dingtalk): mention senders in streamed group replies
Reuse sender metadata and the existing AI Card lifecycle to include native mentions in ordinary group answers. Preserve mentions across progress, completion, and cleanup without sending a separate reminder.

Verified with npm run check (1671 tests) and a real ordinary Q&A in the existing DingTalk test group.
2026-08-28 23:08:52 +08:00
xmanrui
092d2cbb9c test(dingtalk): cover PR #76 mentions and credit contributor
Add regression coverage for group mention chunks, private replies, mention payloads, and batch reply failure handling. Credit divingleee in package contributors and rebuild the checked-in bundles.
2026-08-28 21:51:03 +08:00
xiemanR
799391552e
Merge pull request #76 from divingleee/feat/dingtalk-at-person
dingtalk add @person function
2026-08-28 21:44:54 +08:00
xmanrui
57eef234b1 feat(ui): add manual update commands and simplify update dialog 2026-08-28 15:32:09 +08:00
lbq
f8f0ced2a7 fix error 2026-08-28 12:45:49 +08:00
xmanrui
45c0a7f77f chore: release v3.1.1 2026-08-28 10:53:30 +08:00
xmanrui
6c6d4af936 fix(feishu): preserve long streaming replies
Keep a bounded streaming preview, then deliver the complete final answer across multiple cards. Preserve all provider message IDs and cover long snapshots and Unicode boundaries with regression tests.

Fixes #78
2026-08-28 10:50:35 +08:00
xmanrui
71ca552113 chore: release v3.1.0 2026-08-28 06:42:16 +08:00
xmanrui
f3cefd8a84 feat: add npm update checks and manual installation
Add profile-scoped npm updates for Desktop and Web, protect source installations, and keep restarts manual. Cover stale status recovery, request races, and dialog focus with regression tests.

Verified with npm run check (1626 tests) and isolated Desktop/Web npm installation flows.

Refs #61
2026-08-28 06:37:40 +08:00
xmanrui
5888641297 fix(ui): align channel tabs with scan action 2026-08-28 06:16:27 +08:00
xmanrui
8c6c31a1b6 feat: add bounded history previews across nine channels
Add shared /history parsing, read-only session access, message filtering, and bounded replies. Default to three messages, cap at five, and exclude saved history commands.

Include channel integration tests, translations, command help, and the Issue #62 implementation plan.
2026-08-28 03:01:53 +08:00
xmanrui
bf0e157cd4 chore: release v3.0.8 2026-08-28 01:32:15 +08:00
xmanrui
f0b6b38b45 fix: use in-process Harness API for local plugin connections 2026-08-28 01:24:17 +08:00
xmanrui
f4ded46278 chore: release v3.0.7 2026-08-27 22:37:34 +08:00
xmanrui
4c4c748864 fix(commands): support both Harness command argument formats
Keep images for newer Harness endpoints and retry without it only when an older gateway rejects the field before dispatch. Preserve cancellation and never retry business failures.

Add regression coverage, rebuild the Host bundle, and document the compatibility fix. Follow-up to #75.
2026-08-27 22:11:13 +08:00
lbq
7d5bc94f64 dingtalk add @person function 2026-08-27 22:09:06 +08:00