Skip to main content

a collection of shared components for graia

Project description

Amnesia

A collection of common components for Graia Project.

于是明天仍将到来.

每一天都会带来新的邂逅, 纵使最终忘却也不会害怕明天到来.

PyPI code_style

简述

Amnesia 是一系列共用组件的集合, 包含了以下内容:

  • 消息链 MessageChain, 沿袭自 Avilla 实现和 Ariadne 部分方法实现;
  • Element 基类和 Text 消息元素实现;
  • Launch API: 程序生命周期管理, 提供准备(prepare), 主线(mainline) 与 清理(cleanup) 三个时间节点; 支持依赖编排;
  • 轻量化实现的 Service;
  • 轻量化的内存缓存实现 Memcache, 原版本由 @ProgramRipper 实现, 沿袭自 Avilla;
  • Transport API: 职权分派, 交互主导的网络通信封装;
    • uvicorn: ASGI Runner;
    • starlette: ASGI Application;
    • aiohttp: Http & WebSocket Client.

通过 Amnesia, 我们希望能更加轻量化第三方库的依赖, 并籍此促进社区的发展.

  • MessageChain 可以让 Avilla, Ariadne, Alconna 等共用统一实现, 并使其泛用性扩大;
  • Launch API 可以优化应用的启动流程, 适用于 Saya 或是单纯的 Broadcast Control 应用;
  • Service 使维护和访问资源的流程更加合理;
  • ...或许还会有更多?

协议

本项目以 MIT 协议开源.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

graia_amnesia-0.9.0.tar.gz (17.7 kB view details)

Uploaded Source

Built Distribution

graia_amnesia-0.9.0-py3-none-any.whl (21.9 kB view details)

Uploaded Python 3

File details

Details for the file graia_amnesia-0.9.0.tar.gz.

File metadata

  • Download URL: graia_amnesia-0.9.0.tar.gz
  • Upload date:
  • Size: 17.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.12.1

File hashes

Hashes for graia_amnesia-0.9.0.tar.gz
Algorithm Hash digest
SHA256 0a211c35eb55449b0ecfcdb1793148a1c525205d465e8202c242ab8924fc1ee0
MD5 c0f9ab161e17129381d429153e5eaa5d
BLAKE2b-256 56dc10ef973e26b2839a8097589ea7e250bc257a04f204b7824acca568cc990e

See more details on using hashes here.

File details

Details for the file graia_amnesia-0.9.0-py3-none-any.whl.

File metadata

File hashes

Hashes for graia_amnesia-0.9.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c78fd34e5955122575744a5b7d78fc636cee644e15eea543d68d07dfe12c6cf1
MD5 0eb21cbfe60792fb9421ef5f674d1679
BLAKE2b-256 08dbfa599ec08f015dee18319fa4a0df7fe7ace8108e5327249c0b0e48f5530e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page