dkg-debug-chat

dkg-debug-chat is a cursor rule for Cursor from OriginTrail/dkg. It costs 715 tokens per session, scanned A, original, Apache-2.0.

A set of instructions for two coding agents to exchange encrypted messages through a shared debugging chat. It also tells the agent to check for waiting messages at the start of a session.

In plain words
What is it for?
Use it to read peer messages, send updates, and continue cross-agent debugging work.
Why use it?
It helps agents on different machines coordinate while investigating the same problem.

Cursor rule for Cursor

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/origintrail/dkg/dkg-debug-chat
Clone the repo
git clone --depth 1 https://github.com/OriginTrail/dkg

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for dkg-debug-chat

README.md
[![agentmods](https://agentmods.dev/badge/rules/origintrail/dkg/dkg-debug-chat.svg)](https://agentmods.dev/rules/origintrail/dkg/dkg-debug-chat)
Your own site
<a href="https://agentmods.dev/rules/origintrail/dkg/dkg-debug-chat"><img src="https://agentmods.dev/badge/rules/origintrail/dkg/dkg-debug-chat.svg" alt="Measured on agentmods" height="20"></a>
Per session 715 This file is loaded in full into every session.
When invoked 715 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00715 $0.00715
Opus 5 $0.00358 $0.00358
Sonnet 5 $0.00143 $0.00143
Haiku 4.5 $0.00072 $0.00072

Measured 4d ago against content hash 99f95e7fccd9, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

dkg-debug-chat scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/dkg-debug-chat.mdc · 41 lines

How it starts

The opening of the file, as written. The whole thing — 41 lines — stays where its author put it; the contents beside it link to each section on GitHub.

DKG agent-to-agent debug chat

The two DKG nodes in this workspace can be paired with each other. When they are, you (the Cursor agent on this node) can exchange encrypted libp2p messages with the Cursor / Claude Code / Codex agent on the other node via two MCP tools:

  • dkg_check_inbox — read unread peer messages from this node's local SQLite history.
  • dkg_send_message — send an encrypted chat to another agent on the network.

When to call which

Call dkg_check_inbox at the start of every session. If the digest is non-empty, surface the messages to the operator BEFORE doing anything else — those peers are waiting for a reply. After the operator types anything, your first line should look like:

"Before I get to that — bob-node sent 2 messages while you were away: …"

Call dkg_check_inbox again whenever:

  • The operator's prompt references another node, OR
  • The current task is part of a known cross-node debugging effort, OR
  • You see an injected <dkg-inbox-notice> block in the session context (the prompt-hook may have already fetched fresh messages — re-check anyway to be sure nothing was missed).

Call dkg_send_message whenever the operator says "ask ", "tell ", "let know", "ping ", or otherwise indicates cross-node communication. Use the operator's word for the recipient as to — the daemon resolves it. Don't pause for clarification on recognisable names ("alice's agent" → to: "alice-node").

ACL-aware error handling

If dkg_send_message returns delivered: false with error: "unauthorized: ...", the receiver's chat ACL rejected the message. Don't retry — the situation is human-fixable. Tell the operator something like:

"Receiver rejected my message via their chat ACL: <reason>. Ask the operator on the other node to either add this node to their chat.acl.peerAllowlist, or add us as a member of the CG they have scoped to."

For any other error (peer not found, timeout, network), retry once before bothering the operator.

Read the full file on GitHub · 41 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 41 lines · 715 tokens per session scan A 99f95e7fccd9

Subscribe to this mod's changes

dkg-debug-chat is a cursor rule published in the GitHub repository OriginTrail/dkg (144 stars, last pushed today), licensed Apache-2.0. It adds 715 tokens to every session, about $0.0036 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.