一键导入
tm-world-model
Collective Tsetlin Machine learning. Build a logical world model from observations and share knowledge with peer agents.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Collective Tsetlin Machine learning. Build a logical world model from observations and share knowledge with peer agents.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | tm-world-model |
| description | Collective Tsetlin Machine learning. Build a logical world model from observations and share knowledge with peer agents. |
You have a Tsetlin Machine (TM) that learns logical patterns from binary observations. Your TM state persists between turns. Use these tools to observe, evaluate, and share knowledge.
Your workspace directory for all commands: ~/.openclaw/workspace
Skill scripts directory: {baseDir}
Your agent ID: set by your system prompt (e.g., "agent_a")
python {baseDir}/tm_observe.py \
--workspace ~/.openclaw/workspace \
--agent YOUR_AGENT_ID \
--X 'JSON_ARRAY_OF_FEATURE_VECTORS' \
--y 'JSON_ARRAY_OF_LABELS' \
[--epochs 50] \
[--noise-cols 'COMMA_SEPARATED_COLUMN_INDICES'] \
[--noise-rate 0.45]
--X is a JSON array like [[1,0,1,0,1,0,1,0,1,0,1,0], [0,1,0,1,...]]
--y is a JSON array like [0, 1, 0, 1]
--noise-cols applies simulated noise to specific feature columns before training.
Use this if you know which features your agent observes with noise.
python {baseDir}/tm_evaluate.py \
--workspace ~/.openclaw/workspace \
--agent YOUR_AGENT_ID \
--X 'JSON_ARRAY_OF_TEST_VECTORS' \
--y 'JSON_ARRAY_OF_TEST_LABELS'
Returns: {"ok": true, "accuracy": 0.823, "fitted": true, "n_train_samples": 500}
python {baseDir}/tm_share.py \
--workspace ~/.openclaw/workspace \
--agent YOUR_AGENT_ID \
[--n 500]
Returns: {"ok": true, "packet": "<compact_json_string>", ...}
After getting the packet, send it to a peer session via sessions_send:
Message format: "tm_knowledge_packet:<PACKET_STRING>"
The peer agent will detect this prefix and call tm_absorb.
When you receive a message starting with "tm_knowledge_packet:", extract the packet string (everything after the colon) and run:
python {baseDir}/tm_absorb.py \
--workspace ~/.openclaw/workspace \
--agent YOUR_AGENT_ID \
--packet 'PACKET_STRING_FROM_PEER' \
[--epochs 150]
Returns: {"ok": true, "absorbed_from": "agent_a", "total_samples": 1000}
python {baseDir}/tm_status.py \
--workspace ~/.openclaw/workspace \
--agent YOUR_AGENT_ID
Normal round:
When you should share:
Sharing protocol:
When you receive a knowledge packet: