sdf-com-bridge

Bridge between SDF COM chatroom and Feishu-Lark messaging platform. Supports bi-directional message translation between English and Chinese, command execution, and real-time chat synchronization. Use when connecting to SDF Public Access UNIX System COM chat and relaying messages to Feishu or Lark.

Safety Notice

This listing is from the official public ClawHub registry. Review SKILL.md and referenced scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "sdf-com-bridge" with this command: npx skills add ykaixu/sdf-com-bridge

SDF COM Bridge

SDF COM chatroom to Feishu bridge with real-time message sync and translation.

Architecture

  • SSH Socket connects to SDF
  • COM runs on remote
  • Terminal Parser extracts messages
  • Translator handles EN-ZH bidirectional translation
  • Feishu Integration sends formatted messages

Components

1. SSH Connection (scripts/ssh_connection.py)

Reuses ControlMaster socket for connection.

from ssh_connection import SSHConnection

conn = SSHConnection(user="yupeng", host="sdf.org")
conn.connect("com -c")  # Start COM
conn.send("g anonradio\n")  # Enter room

2. COM Interaction (scripts/com_interaction.py)

COM command wrapper.

CommandFunctionDescription
wget_users()List users
llist_rooms()List rooms
gjoin_room("name")Join room
r/Rget_history(n)View history
ssend_private(user, host, msg)Private message
eemote(action)Emote action
qquit()Exit COM

3. Terminal Parser (scripts/terminal_parser.py)

Extracts chat messages from terminal output.

from terminal_parser import SimpleTextParser

parser = SimpleTextParser()
messages = parser.feed(raw_text)

4. Translator (scripts/translator.py)

English to Chinese translation.

from translator import LLMTranslator

translator = LLMTranslator()
zh = translator.quick_translate_en_to_zh("hello")

5. Feishu Bridge (scripts/feishu_bridge.py)

Parse Feishu commands.

CommandFormatFunction
Sendcom: messageSend to COM
Statuscom:pwdCheck connection
Privmsgs: user@host messagePrivate message

6. Main Bridge (scripts/main.py)

Complete runtime example.

from main import SDFComBridge

bridge = SDFComBridge(
    user="yupeng",
    host="sdf.org",
    target_room="anonradio"
)

bridge.start()
bridge.handle_feishu_message("com: hello")
bridge.stop()

Usage

Install dependencies:

pip install -r requirements.txt

Run directly:

python scripts/main.py

Test connection:

python -c "from scripts.ssh_connection import SSHConnection; c = SSHConnection(); print(c._check_socket())"

Configuration

Edit main.py:

bridge = SDFComBridge(
    user="yupeng",
    host="sdf.org",
    target_room="anonradio"
)

Default Room

Auto-joins anonradio chatroom.

Message Flow

COM to Feishu:

  • English messages auto-translated to Chinese

Feishu to COM:

  • Messages prefixed with "com:" sent to COM

Notes

  • Requires existing SSH ControlMaster socket
  • Socket path: ~/.ssh/sockets/yupeng@sdf.org
  • com command must be available on remote
  • pyte requires correct terminal size (80x24 default)

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

General

Power Automate Monitoring

**Pro+ subscription required.** Tenant-wide Power Automate flow health monitoring, failure rate analytics, and asset inventory using the FlowStudio MCP cache...

Registry SourceRecently Updated
General

Power Automate Governance

Govern Power Automate flows and Power Apps at scale using the FlowStudio MCP cached store. Classify flows by business impact, detect orphaned resources, audi...

Registry SourceRecently Updated
General

Secretary Memory

OpenClaw 秘书式多分区记忆系统 v3.0。仿生现代秘书的笔记本分类法,支持:(1) 多分区并发搜索 + 每分区3条上下文召回,(2) 会话自动摘要,(3) 偏好自动提取 + 用户关系图谱,(4) 记忆冲突主动检测,(5) 定时 consolidation + 会话结束 hook,(6) 精细化恢复/回溯,...

Registry SourceRecently Updated
General

运维助手 v2.0

运维助手 v2.0 - 支持本地、远程、多服务器集群监控 (健康检查、日志分析、性能监控、批量操作、文件传输)

Registry SourceRecently Updated