TG-BOT 插件作者侧 SDK 与 capability 真源模型。
Project description
tg-bot-plugin-sdk
tg-bot-plugin-sdk 是 TG-BOT 插件作者侧 Python API 的新真源。
当前阶段提供:
BasePlugin与PluginContextCapabilityResult与RuntimeCapabilityInvocationconcurrency_class常量与PluginCapabilitySpecBackgroundTaskHandle/BackgroundTaskObserverinvoke_capability/event_capability装饰器CapabilityDeclarationError/PluginError- capability 真源投影与 externalize 输出脚本
作者侧 ABI 约束:
PluginCapabilitySpec.concurrency_class固定为sync_session / async_sidecar / async_terminal,默认sync_sessionRuntimeCapabilityInvocation固定提供message_thread_id、session_key、session_kindPluginContext不默认暴露shard_id、worker_id、host_id这类内部调度字段
packages/sdk/scripts/externalize_capabilities.py 会生成
build/capabilities.externalize.json,后续由 packages/buildkit 消费并把 capability
投影刷新回 manifest.json。
本地验证
- 独立安装与导入验证:
bash packages/sdk/scripts/check_package_install.sh - 单元测试:
pytest -q packages/sdk/tests
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tg_bot_plugin_sdk-0.2.0-py3-none-any.whl.
File metadata
- Download URL: tg_bot_plugin_sdk-0.2.0-py3-none-any.whl
- Upload date:
- Size: 34.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a84e63ab1555e7cdb2d086731681a0f3cfd0f4d0e97bfc6edeb2e239aa5aecbe
|
|
| MD5 |
ac701bd969af59b467109dedc1ab147f
|
|
| BLAKE2b-256 |
cb24fdae194be1b8f6f2c517b326c0d694bef4e6eee44a9984865d63109b0b28
|
Provenance
The following attestation bundles were made for tg_bot_plugin_sdk-0.2.0-py3-none-any.whl:
Publisher:
release-sdk.yml on Fire-Dragons/TG-BOT
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
tg_bot_plugin_sdk-0.2.0-py3-none-any.whl -
Subject digest:
a84e63ab1555e7cdb2d086731681a0f3cfd0f4d0e97bfc6edeb2e239aa5aecbe - Sigstore transparency entry: 1439049502
- Sigstore integration time:
-
Permalink:
Fire-Dragons/TG-BOT@0be7193c0be0f3d57bcbd5fcf301aef5929a261b -
Branch / Tag:
refs/tags/sdk-v0.2.0 - Owner: https://github.com/Fire-Dragons
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-sdk.yml@0be7193c0be0f3d57bcbd5fcf301aef5929a261b -
Trigger Event:
push
-
Statement type: