Logo Challenge Inference Protocol

Challenge Inference Protocol

Tổ chứcPhổ biến
AgibotTech
challenge-inference-protocol

Reference for the Simulation Challenge inference wire protocol — the exact obs (input) and action (output) message format exchanged between the gateway/genie-sim simulator and the contestant's inference agent over the reverse WebSocket tunnel. Covers the JSON-RPC envelope, image encoding, per-board state/action joint layout, the plain-msgpack response caveat, and the authoritative source files. Trigger: When the user asks about "推理接口协议", "inference protocol", "obs/action format", "观测/动作格式", "网关下发什么", "agent 返回什么", "what does the gateway send", "result envelope", "state layout", "动作怎么拆", or needs to implement/debug the obs→model→action adapter in a tunnel agent.

Tổng quan

Nhà phát hànhAgibotTech
Kho mãgenie_sim
Tên kỹ năngchallenge-inference-protocol
Sao
1.4K
Bản fork
119
Tệp đi kèm
Chỉ có hướng dẫn
Liên kết
  • Hướng dẫn bằng Markdown

    Tệp SKILL.md được mô hình tải khi cần, nên chỉ tốn token khi có yêu cầu thực sự phù hợp.

  • Dùng được với mọi LLM

    Kỹ năng AI là Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên dùng được với GPT, Claude, Gemini, Grok hoặc mô hình cục bộ.

  • Đầy đủ trong hướng dẫn

    Mọi thứ mô hình cần đều nằm trong hướng dẫn — không có tệp bổ sung cần đồng bộ.

  • Mã nguồn mở

    Được AgibotTech công bố trên GitHub. Hãy đọc nội dung nguồn trước khi cài đặt.

Cài đặt

Cài đặt kỹ năng AI Challenge Inference Protocol trong TypingMind để dùng với bất kỳ LLM nào, hoặc thêm vào một tác nhân AI khác có thể đọc SKILL.md.

1

Cài đặt trong TypingMind

TypingMind cài đặt kỹ năng trực tiếp từ thư mục GitHub — đọc SKILL.md, đóng gói các tệp tài nguyên và lưu kết quả trên máy.

  1. Mở ứng dụng và vào Plugin → Kỹ năng.
  2. Chọn "Cài đặt từ GitHub".
  3. Dán URL thư mục kỹ năng bên dưới và xác nhận.
    https://github.com/AgibotTech/genie_sim/tree/main/source/geniesim_benchmark/skills/robocoliseum/challenge-inference-protocol
  4. Bật kỹ năng trong từng cuộc trò chuyện mà bạn muốn sử dụng kỹ năng đó.
Plugin → Kỹ năng → Thêm kỹ năng → Từ URL GitHub, sau đó dán URL thư mục và nhấn Tiếp tục.
2

Cài đặt trong tác nhân AI khác

Bất kỳ tác nhân AI nào đọc được định dạng Agent Skills đều có thể dùng kỹ năng này — hãy sao chép thư mục vào thư mục kỹ năng của tác nhân AI đó.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/AgibotTech/genie_sim.git /tmp/genie_sim
mkdir -p .claude/skills
cp -r /tmp/genie_sim/source/geniesim_benchmark/skills/robocoliseum/challenge-inference-protocol .claude/skills/challenge-inference-protocol
Khởi động lại Claude Code sau khi sao chép để ứng dụng nhận kỹ năng mới.

Sử dụng trong TypingMind

Bật Challenge Inference Protocol trong bất kỳ cuộc trò chuyện nào trên TypingMind, mô hình sẽ tự xử lý phần còn lại. Tên và mô tả của kỹ năng nằm trong prompt hệ thống. Ngay khi có yêu cầu phù hợp, mô hình tự tải toàn bộ hướng dẫn — bạn không cần gọi thủ công và kỹ năng không tốn token cho đến khi thực sự được dùng.

Mô hình tự tải Challenge Inference Protocol ngay khi có yêu cầu phù hợp.

Dùng được với mọi mô hình AI

Kỹ năng AI là các hướng dẫn Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên Challenge Inference Protocol không bị giới hạn ở mô hình mà kỹ năng này được viết cho. Chỉ cần cài đặt một lần trong TypingMind rồi dùng với GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama hoặc mô hình cục bộ do bạn tự chạy — tất cả đều dùng khóa API của riêng bạn.

  • Chỉ tải khi cần

    Prompt hệ thống chỉ chứa tên và mô tả. Hướng dẫn được tải khi có yêu cầu phù hợp đầu tiên, nên kỹ năng chưa dùng không tốn chi phí.

  • Đổi mô hình ngay trong cuộc trò chuyện

    Vì kỹ năng là hướng dẫn chứ không phải mã, việc đổi mô hình không làm kỹ năng ngừng hoạt động — mô hình tiếp theo vẫn đọc cùng tệp SKILL.md.

Hướng dẫn của kỹ năng

Đây là nội dung SKILL.md mà mô hình tải. Hãy đọc trước khi cài đặt — kỹ năng là những hướng dẫn mà mô hình của bạn sẽ làm theo.

challenge-inference-protocol — Inference wire protocol (obs in / action out)

This documents the application-layer payload the Simulation Challenge gateway (driven by the genie-sim simulator) exchanges with a contestant inference agent. The transport (reverse WebSocket tunnel, control frames, data-frame framing) is specified in the appendix of challenge-run-agent; this skill covers only what goes inside the data-frame payload.

The gateway treats the payload as opaque bytes. The schema below is defined by the genie-sim client, not the gateway. Authoritative source: main/source/geniesim/benchmark/policy/corobotpolicy.py — get_payload() builds the request, _parse_result() / infer() parse the response. Reference agent implementation: ACoT-VLA/scripts/tunnel_agent.py — _adapt_obs() (input), _build_action_response() (output).


1. Input — observation (gateway → agent)

A msgpack-encoded JSON-RPC envelope. Decode with msgpack_numpy.unpackb (str keys).

jsonc
{
  "method": "infer",
  "params": {
    "timestamps": { "head": <ns int>, "states": <ns int> },
    "images": {
      "head":       { "encoding": "JPEG", "image_data": <bytes>, "height": 400,  "width": 640  },
      "hand_left":  { "encoding": "JPEG", "image_data": <bytes>, "height": 1056, "width": 1280 },
      "hand_right": { "encoding": "JPEG", "image_data": <bytes>, "height": 1056, "width": 1280 }
    },
    "states": {
      "head_joint_states":  [],          // 0 dims on G2_omnipicker
      "arm_joint_states":   [ ...14 ],   // left_arm(7) + right_arm(7)
      "waist_joint_states": [ ...5  ],
      "gripper_states":     [ ...2  ]    // [left, right]
    },
    "prompt":        "<natural-language task instruction>",
    "robot_type":    "G2_omnipicker",
    "task_name":     "pick_block_color",
    "episode_idx":   0,
    "episode_done":  false,
    "task_progress": [ ... ]
  }
}

Image decode: each camera is JPEG bytes under image_data. Decode with cv2.imdecode(IMREAD_COLOR) → HWC BGR, then convert to RGB (the model expects RGB HWC uint8). Depth fields (*_depth) exist in the schema but are commented out / not sent today.

Camera rename to the model's expected names: head→top_head, hand_left→hand_left, hand_right→hand_right.

State assembly for the model (matches training state_keys order joint, left_effector, right_effector, waist):

state = concat(arm_joint_states[14], gripper_states[2], waist_joint_states[5])  # = 21 on G2

One assembly works for all boards: configs with include_waist=False (instruction / spatial) mask the trailing waist dims to zero, so the extra 5 dims are harmless; include_waist=True (manip) needs waist in dims 16–20. info.json is absent at inference, so state_indices=None (no remapping) — the agent must hand the model the already-ordered vector.


2. Output — action (agent → gateway)

A msgpack-encoded result envelope:

jsonc
{
  "result": {
    "left_arm":       { "kind": "JOINT_ABS", "values": [[...7], ...H] },
    "right_arm":      { "kind": "JOINT_ABS", "values": [[...7], ...H] },
    "left_effector":  [[...1], ...H],
    "right_effector": [[...1], ...H],
    "waist":          { "kind": "JOINT_ABS", "values": [[...5], ...H] }   // optional; manip waist tasks only
  }
}
  • H = action horizon (instruction/spatial: 50, manip: 30). The sim buffers the whole chunk and replans when it drains.
  • kind: JOINT_ABS (absolute joint positions, what this model emits) or EEF_ABS (end-effector pose, IK-solved sim-side). left_arm.kind and right_arm.kind must match.
  • The sim reads result["result"]; a top-level {"error": "..."} is treated as a fatal server error.

Map a model action chunk acts[H, D] → the envelope:

slicefield
acts[:, 0:7]left_arm.values
acts[:, 7:14]right_arm.values
acts[:, 14:15]left_effector
acts[:, 15:16]right_effector
acts[:, 16:]waist.values (only when D > 16)

instruction/spatial emit D=16 (no waist key); manip emits D=21 only on waist tasks (e.g. sorting_packages), else 16.

⚠️ The plain-msgpack caveat (most common output bug)

genie-sim unpacks the response with plain msgpack (raw=False), NOT msgpack_numpy. If you pack numpy arrays they arrive as ext-encoded garbage and np.array(values) breaks. Convert every array to native Python lists (.tolist()) before packing. Packing the list-only dict with either msgpack or msgpack_numpy is fine.


3. Per-board model layout

Board (config.board)train configckpt dirhorizonstate/action dims
instruction, robustpi05_genie_sim_instruction_and_robust_20260526checkpoints/instruction_and_robust5016 (no waist)
spatialpi05_genie_sim_spatial_20260511checkpoints/spatial5016 (no waist)
manippi05_genie_sim_manip_20260526checkpoints/manipulation3021 (include_waist=True)

ACOT_BOARD=<board> ./scripts/tunnel.sh <gpu> <job_uuid> <gateway> selects config+ckpt. The board the agent serves must match the config.board of the submitted job.


4. Quick checklist when debugging the adapter

  • KeyError: 'state' in the policy → you fed raw params to the model; run _adapt_obs first (gateway no longer sends a flat top-level state).
  • Sessions open/close rapidly with no stepping, job stuck at 0 → response format wrong (sim can't parse result["result"]); check the envelope keys and the .tolist() caveat.
  • Black/garbled images → forgot BGR→RGB, or fed CHW where HWC expected.
  • manip arm flailing / waist ignored → waist not included in state (dims 16–20) or not emitted in the action envelope.

Câu hỏi thường gặp

Kỹ năng AI Challenge Inference Protocol làm được gì?

Reference for the Simulation Challenge inference wire protocol — the exact obs (input) and action (output) message format exchanged between the gateway/genie-sim simulator and the contestant's inference agent over the reverse WebSocket tunnel. Covers the JSON-RPC envelope, image encoding, per-board state/action joint layout, the plain-msgpack response caveat, and the authoritative source files. Trigger: When the user asks about "推理接口协议", "inference protocol", "obs/action format", "观测/动作格式", "网关下发什么", "agent 返回什么", "what does the gateway send", "result envelope", "state layout", "动作怎么拆", or...

Vì sao nên dùng Challenge Inference Protocol trên TypingMind?

Vì bạn chỉ cần cài một lần rồi dùng với bất kỳ mô hình nào. Challenge Inference Protocol là nội dung Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên cùng một kỹ năng có thể chạy trên GPT-5, Claude, Gemini, Grok hoặc mô hình trên thiết bị — và bạn có thể đổi mô hình ngay trong cuộc trò chuyện mà kỹ năng vẫn hoạt động. TypingMind dùng khóa API riêng của bạn, nên bạn thanh toán trực tiếp cho nhà cung cấp thay vì trả phí thuê bao theo suất người dùng, đồng thời kỹ năng và các cuộc trò chuyện vẫn nằm trong bộ lưu trữ của bạn.

Làm thế nào để cài Challenge Inference Protocol trong TypingMind?

Mở Plugin → Kỹ năng → Cài đặt từ GitHub trong TypingMind rồi dán https://github.com/AgibotTech/genie_sim/tree/main/source/geniesim_benchmark/skills/robocoliseum/challenge-inference-protocol. TypingMind đọc tệp SKILL.md và cài đặt thành một kỹ năng mà bạn có thể bật cho từng cuộc trò chuyện.

Những mô hình AI nào có thể dùng Challenge Inference Protocol?

Bất kỳ mô hình nào bạn kết nối trong TypingMind. Kỹ năng AI là các hướng dẫn bằng Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên GPT, Claude, Gemini, Grok và các mô hình chạy trên thiết bị đều có thể tải kỹ năng này khi có yêu cầu phù hợp.

Bạn có thể dùng Challenge Inference Protocol với bao nhiêu mô hình AI?

Bao nhiêu cũng được. Miễn là mô hình hỗ trợ kỹ năng, bạn có thể dùng Challenge Inference Protocol với mô hình đó — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama và nhiều mô hình khác — tất cả đều trên TypingMind với khóa API riêng của bạn.

Kỹ năng AI Challenge Inference Protocol có miễn phí không?

Kỹ năng này được AgibotTech phát hành trên GitHub. Hãy xem điều khoản giấy phép trong kho mã. Bạn chỉ trả tiền cho nhà cung cấp AI của mình theo số token đã dùng.

Kỹ năng AI là gì?

Kỹ năng AI là một gói hướng dẫn có thể tái sử dụng, chỉ cho mô hình AI cách thực hiện một tác vụ cụ thể. Kỹ năng tuân theo định dạng mở Agent Skills: một tệp SKILL.md chứa tên và mô tả, cùng các tập lệnh, mẫu hoặc tệp tham khảo mà mô hình có thể cần. Mô hình chỉ đọc hướng dẫn khi yêu cầu của bạn phù hợp với kỹ năng, nên kỹ năng đã cài đặt không phát sinh chi phí cho đến khi được sử dụng.

Kỹ năng AI khác gì với plugin hoặc máy chủ MCP?

Plugin hoặc máy chủ MCP cung cấp cho mô hình các công cụ mới để gọi — mã được chạy ở đâu đó và trả về kết quả. Còn kỹ năng AI cung cấp kiến thức và quy trình: cách tiếp cận tác vụ, các bước cần thực hiện và tiêu chí của đầu ra tốt. Kỹ năng chỉ là nội dung Markdown, nên không cần máy chủ, khóa API hay môi trường thực thi và hoạt động với mọi mô hình.

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇