瀏覽代碼

Replace hand-rolled protobuf, WebSocket and REST with chattolib

The adapter maintained ~950 lines of manual protobuf encoding/decoding,
WebSocket framing and raw HTTP calls that chattolib already ships - every
protocol change had to be chased twice. chattolib[realtime] becomes the
single API surface: login and client state, rooms, messages, presence,
notifications, and stream_events() for realtime delivery instead of a
hand-rolled socket loop. This first half swaps the core; the remaining
_rpc() call sites follow in the next commit.
Paul Klumpp 1 月之前
父節點
當前提交
ce0993fbdc
共有 2 個文件被更改,包括 118 次插入886 次删除
  1. 92 886
      adapter.py
  2. 26 0
      pyproject.toml

File diff suppressed because it is too large
+ 92 - 886
adapter.py


+ 26 - 0
pyproject.toml

@@ -0,0 +1,26 @@
+[build-system]
+requires = ["setuptools>=68.0"]
+build-backend = "setuptools.build_meta"
+
+[project]
+name = "hermes-chatto-plugin"
+version = "1.0.0"
+description = "Chatto platform adapter for Hermes Agent"
+requires-python = ">=3.11"
+license = {text = "MIT"}
+authors = [
+    {name = "liv", email = ""},
+]
+dependencies = [
+    "chattolib[realtime]>=0.4.19",
+    "websockets>=13.0",
+]
+
+[project.optional-dependencies]
+dev = [
+    "pytest>=8.0",
+    "pytest-asyncio>=0.24",
+]
+
+[tool.setuptools.packages.find]
+where = ["."]

Some files were not shown because too many files changed in this diff