Make your computer a home for your AI partner. Avibe is the local-first Agent OS: Vibey, its built-in AI partner, works out of the box, and Claude Code, Codex & OpenCode run unchanged beside it — reach them from your browser, phone, or any chat app.
Python agentagent-osaiai-agentsai-partnerchatopsclaudeclaude-codecodexdevtoolsdiscord-botlark-botllmlocal-firstlong-term-memoryopencodeslack-botvibe-codingvibeywechat
refactor(platforms): clarify typing indicator capabilities
cyh8a4d94ba8f33
diff --git a/config/platform_registry.py b/config/platform_registry.pyindex 585190220..b29a12661 100644--- a/config/platform_registry.py+++ b/config/platform_registry.py@@ -16,11 +16,12 @@ class PlatformCapabilities:supports_message_editing: boolmarkdown_upload_returns_message_id: bool = Falsequick_reply_single_column: bool = False- supports_processing_typing: bool = False- processing_typing_requires_clear: bool = False- supports_processing_reaction: bool = False- supports_processing_message: bool = True- supports_processing_message_delete: bool = False+ supports_typing_indicator: bool = False+ typing_indicator_requires_clear: bool = False+ typing_indicator_best_effort: bool = False+ supports_reaction_indicator: bool = False+ supports_message_indicator: bool = True+ supports_message_indicator_delete: bool = Falsepreferred_processing_indicator: str = "typing"force_preferred_processing_indicator: bool = False@@ -114,8 +115,9 @@ PLATFORM_REGISTRY: dict[str, PlatformDescriptor] = {supports_buttons=True,supports_quick_replies=True,supports_message_editing=True,- supports_processing_typing=True,- supports_processing_reaction=True,+ supports_typing_indicator=True,+ typing_indicator_best_effort=True,+ supports_reaction_indicator=True,),),"discord": PlatformDescriptor(@@ -135,8 +137,8 @@ PLATFORM_REGISTRY: dict[str, PlatformDescriptor] = {supports_quick_replies=True,supports_message_editing=True,markdown_upload_returns_message_id=True,- supports_processing_typing=True,- supports_processing_reaction=True,+ supports_typing_indicator=True,+ supports_reaction_indicator=True,),),"telegram": PlatformDescriptor(@@ -157,9 +159,9 @@ PLATFORM_REGISTRY: dict[str, PlatformDescriptor] = {supports_message_editing=True,markdown_upload_returns_message_id=True,quick_reply_single_column=True,- supports_processing_typing=True,- supports_processing_reaction=True,- supports_processing_message_delete=True,+ supports_typing_indicator=True,+ supports_reaction_indicator=True,+ supports_message_indicator_delete=True,),),"lark": PlatformDescriptor(@@ -180,7 +182,7 @@ PLATFORM_REGISTRY: dict[str, PlatformDescriptor] = {supports_message_editing=True,markdown_upload_returns_message_id=True,quick_reply_single_column=True,- supports_processing_reaction=True,+ supports_reaction_indicator=True,preferred_processing_indicator="reaction",),),@@ -200,9 +202,9 @@ PLATFORM_REGISTRY: dict[str, PlatformDescriptor] = {supports_buttons=False,supports_quick_replies=False,supports_message_editing=False,- supports_processing_typing=True,- processing_typing_requires_clear=True,- supports_processing_reaction=False,+ supports_typing_indicator=True,+ typing_indicator_requires_clear=True,+ supports_reaction_indicator=False,preferred_processing_indicator="typing",force_preferred_processing_indicator=True,),diff --git a/core/processing_indicator.py b/core/processing_indicator.pyindex eceb37b94..a496690be 100644--- a/core/processing_indicator.py+++ b/core/processing_indicator.py@@ -107,11 +107,11 @@ class ProcessingIndicatorService:context: MessageContext,) -> bool:if mode == "typing":- return capabilities.supports_processing_typing+ return capabilities.supports_typing_indicatorif mode == "reaction":- return capabilities.supports_processing_reaction and bool(context.message_id)+ return capabilities.supports_reaction_indicator and bool(context.message_id)if mode == "message":- return capabilities.supports_processing_message+ return capabilities.supports_message_indicatorreturn Falsedef _candidate_modes(self, capabilities: PlatformCapabilities) -> list[str]:@@ -243,10 +243,10 @@ class ProcessingIndicatorService:return handle.contextdef _should_delete_ack_message(self, handle: ProcessingIndicatorHandle) -> bool:- return self._capabilities(handle.context).supports_processing_message_delete+ return self._capabilities(handle.context).supports_message_indicator_deletedef _should_clear_typing_indicator(self, handle: ProcessingIndicatorHandle) -> bool:- return self._capabilities(handle.context).processing_typing_requires_clear+ return self._capabilities(handle.context).typing_indicator_requires_clearasync def _delete_ack_message_for_handle(self,diff --git a/docs/plans/processing-indicator-lifecycle.md b/docs/plans/processing-indicator-lifecycle.mdindex 3a0fb845f..81f8779d2 100644--- a/docs/plans/processing-indicator-lifecycle.md+++ b/docs/plans/processing-indicator-lifecycle.md@@ -32,11 +32,14 @@ The registry owns ACK/typing differences:- which platforms can use typing, reaction, or message indicators- whether typing requires an explicit clear operation+- whether typing support is best-effort rather than a stable platform path- whether message ACKs can be deleted- whether a platform has a preferred or forced indicator modeThis keeps WeChat's explicit cancel requirement, Lark's reaction preference, and-Telegram's message-delete support out of backend-specific code.+Telegram's sendChatAction/message-delete support out of backend-specific code.+Slack is marked as typing-capable but best-effort because it relies on legacy+RTM availability.## Compatibility Boundarydiff --git a/tests/test_platform_registry.py b/tests/test_platform_registry.pyindex e3ecc3d07..6e4d7ad29 100644--- a/tests/test_platform_registry.py+++ b/tests/test_platform_registry.py@@ -15,12 +15,16 @@ def test_platform_catalog_exposes_capability_flags() -> None:assert catalog["telegram"]["capabilities"]["supports_threads"] is Falseassert catalog["wechat"]["capabilities"]["supports_buttons"] is Falseassert catalog["wechat"]["capabilities"]["supports_channels"] is False- assert catalog["wechat"]["capabilities"]["supports_processing_typing"] is True- assert catalog["wechat"]["capabilities"]["processing_typing_requires_clear"] is True+ assert catalog["slack"]["capabilities"]["supports_typing_indicator"] is True+ assert catalog["slack"]["capabilities"]["typing_indicator_best_effort"] is True+ assert catalog["telegram"]["capabilities"]["supports_typing_indicator"] is True+ assert catalog["telegram"]["capabilities"]["typing_indicator_requires_clear"] is False+ assert catalog["wechat"]["capabilities"]["supports_typing_indicator"] is True+ assert catalog["wechat"]["capabilities"]["typing_indicator_requires_clear"] is Trueassert catalog["wechat"]["capabilities"]["force_preferred_processing_indicator"] is True- assert catalog["lark"]["capabilities"]["supports_processing_typing"] is False+ assert catalog["lark"]["capabilities"]["supports_typing_indicator"] is Falseassert catalog["lark"]["capabilities"]["preferred_processing_indicator"] == "reaction"- assert catalog["telegram"]["capabilities"]["supports_processing_message_delete"] is True+ assert catalog["telegram"]["capabilities"]["supports_message_indicator_delete"] is Truedef test_credential_readiness_comes_from_platform_descriptor() -> None:diff --git a/ui/src/lib/platforms.ts b/ui/src/lib/platforms.tsindex 1d14f7075..dd3f32083 100644--- a/ui/src/lib/platforms.ts+++ b/ui/src/lib/platforms.ts@@ -8,11 +8,12 @@ export type PlatformCapabilities = {supports_message_editing?: boolean;markdown_upload_returns_message_id?: boolean;quick_reply_single_column?: boolean;- supports_processing_typing?: boolean;- processing_typing_requires_clear?: boolean;- supports_processing_reaction?: boolean;- supports_processing_message?: boolean;- supports_processing_message_delete?: boolean;+ supports_typing_indicator?: boolean;+ typing_indicator_requires_clear?: boolean;+ typing_indicator_best_effort?: boolean;+ supports_reaction_indicator?: boolean;+ supports_message_indicator?: boolean;+ supports_message_indicator_delete?: boolean;preferred_processing_indicator?: string;force_preferred_processing_indicator?: boolean;};@@ -39,9 +40,10 @@ const LEGACY_FALLBACK_CATALOG: PlatformDescriptor[] = [supports_buttons: true,supports_quick_replies: true,supports_message_editing: true,- supports_processing_typing: true,- supports_processing_reaction: true,- supports_processing_message: true,+ supports_typing_indicator: true,+ typing_indicator_best_effort: true,+ supports_reaction_indicator: true,+ supports_message_indicator: true,preferred_processing_indicator: 'typing',},},@@ -58,9 +60,9 @@ const LEGACY_FALLBACK_CATALOG: PlatformDescriptor[] = [supports_quick_replies: true,supports_message_editing: true,markdown_upload_returns_message_id: true,- supports_processing_typing: true,- supports_processing_reaction: true,- supports_processing_message: true,+ supports_typing_indicator: true,+ supports_reaction_indicator: true,+ supports_message_indicator: true,preferred_processing_indicator: 'typing',},},@@ -78,10 +80,10 @@ const LEGACY_FALLBACK_CATALOG: PlatformDescriptor[] = [supports_message_editing: true,markdown_upload_returns_message_id: true,quick_reply_single_column: true,- supports_processing_typing: true,- supports_processing_reaction: true,- supports_processing_message: true,- supports_processing_message_delete: true,+ supports_typing_indicator: true,+ supports_reaction_indicator: true,+ supports_message_indicator: true,+ supports_message_indicator_delete: true,preferred_processing_indicator: 'typing',},},@@ -99,8 +101,8 @@ const LEGACY_FALLBACK_CATALOG: PlatformDescriptor[] = [supports_message_editing: true,markdown_upload_returns_message_id: true,quick_reply_single_column: true,- supports_processing_reaction: true,- supports_processing_message: true,+ supports_reaction_indicator: true,+ supports_message_indicator: true,preferred_processing_indicator: 'reaction',},},@@ -116,10 +118,10 @@ const LEGACY_FALLBACK_CATALOG: PlatformDescriptor[] = [supports_buttons: false,supports_quick_replies: false,supports_message_editing: false,- supports_processing_typing: true,- processing_typing_requires_clear: true,- supports_processing_reaction: false,- supports_processing_message: true,+ supports_typing_indicator: true,+ typing_indicator_requires_clear: true,+ supports_reaction_indicator: false,+ supports_message_indicator: true,preferred_processing_indicator: 'typing',force_preferred_processing_indicator: true,},