feat(session): complete session command and dashboard controls - #185
Merged
Merged
Conversation
Add IM TTS switches, session info/name targeting, alias clearing, and watch listing by listener. Persist Dashboard display names on the UMO alias store and expose session_blocked in the custom-rules editor. AI-Generated: true Generated-At: 2026-09-13T18:43:13Z
Route session info through SessionCapability.parse so builtin commands do not import astrbot.core. Narrow Dashboard alias-sync input for pyright. AI-Generated: true Generated-At: 2026-09-13T19:31:59Z
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Close the remaining IM and Dashboard gaps on session identity, service switches, aliases, watches, and full-block.
Related issue
Fixes #184
Behavior
/tts status|enable|disabletoggles TTS for the current session. It requiressession.manageand is idempotent, same as/llm./session info [this|UMO]can inspect another session. An explicit UMO requiresinstance_operatoror above and shows that session's auto name and alias, not the caller's UID or subject./session name [--target UMO] [--clear]can set or clear the display alias on the current or another session./session watches [listener|this]lists watches for a chosen listener session assource -> target (seconds).user_alias(same store as/session name) and stop persistingcustom_nameon save. Leftovercustom_namestill displays until the next save.session_blocked). The batch session-service API accepts the same field.Non-goals
/ttstoggle.custom_namerows.Implementation notes
/botand/sessionthroughcommands/target.py.session_service_config.custom_nameis copied ontoumo_alias.user_aliasinupdate_session_rule, then stripped from the stored rule.BatchSessionServiceRequestaddssession_blocked. Generated client anddocs/public/openapi.jsonwere regenerated together.bridges.list.Validation
176 focused pytest cases passed. Dashboard i18n check and
sessionManagementPageVitest passed.make checkand full pytest were not run.Compatibility and risk
custom_nameis no longer stored insession_service_config; display usesuser_alias.PATCH /api/v1/sessions/serviceaccepts optionalsession_blocked. Existing callers that omit it are unchanged.Checklist
docs/zh/anddocs/en/.docs/public/openapi.json, and tests change together when routes or schemas change.pyproject.toml,requirements.txt, anduv.locktogether.!and aBREAKING CHANGE:footer.Agent note
Goal: make IM session commands and the custom-rules page cover identity, aliases, TTS, watches, and full-block on the current path, without adding plugin/KB IM commands or a watch Dashboard.
Paths:
astrbot/builtin_stars/builtin_commands/,astrbot/core/platform/session_bridge.py,astrbot/core/star/plugin_context.py,astrbot/dashboard/services/session_management_service.py,dashboard/src/views/SessionManagementPage.vue, OpenAPI + generated client, bilingual docs, focused unit tests.Checks actually run: ruff on touched Python; 176 focused pytest cases; Dashboard i18n check;
sessionManagementPageVitest; OpenAPI client/docs regeneration and Prettier; markdownlint-cli2 on touched docs. Did not runmake checkor full pytest.Residual risk: leftover
custom_nameremains until the next service-config save; watch list text format changed;make checkwas not run in this session.Tools: opencode / grok-4.6, local source, ruff, pytest, pnpm, prettier, markdownlint-cli2, gh. Followed AGENTS.md, AI_POLICY.md, .agents/shared/conventional-commit/REFERENCE.md, and .agents/shared/ai-contribution/REFERENCE.md.