xia-group

xia-group is a command for Claude Code from spideynolove/claude-dotfiles. It costs 25 tokens per session (1,435 once invoked), scanned B, original, MIT.

A command that runs sequential comparison-and-distillation rounds across a ranked list of code repositories. Each round updates the current codebase before the next repository is examined.

In plain words
What is it for?
Use it to study several repositories in order, extract patterns around a chosen topic, and store the resulting progress and notes in the project’s .claude/xia directory.
Why use it?
It preserves useful findings without repeatedly comparing external repositories directly or losing what earlier rounds already contributed.

Command for Claude Code

Written for Claude Code: argument-hint in frontmatter.

Good fit Use it to study several repositories in order, extract patterns around a…

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/spideynolove/claude-dotfiles/xia-group
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.

Clone the repo
git clone --depth 1 https://github.com/spideynolove/claude-dotfiles

Made for: Claude Code.

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 xia-group

README.md
[![agentmods](https://agentmods.dev/badge/commands/spideynolove/claude-dotfiles/xia-group.svg)](https://agentmods.dev/commands/spideynolove/claude-dotfiles/xia-group)
Your own site
<a href="https://agentmods.dev/commands/spideynolove/claude-dotfiles/xia-group"><img src="https://agentmods.dev/badge/commands/spideynolove/claude-dotfiles/xia-group.svg" alt="Measured on agentmods" height="20"></a>
Per session 25 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,435 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00025 $0.01435
Opus 5 $0.00013 $0.00718
Sonnet 5 $0.00005 $0.00287
Haiku 4.5 $0.00003 $0.00144

Measured 6d ago against content hash 445b95f4bcb4, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade B, and why

xia-group scanned grade B with 1 finding 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 6d 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.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

cat .claude/xia/groups/xia-group-$GROUP_NAME.md 2>/dev/null || echo "GROUP_MISSING"
.claude-global-backup/commands/xia-group.md · 210 lines

How it starts

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

/xia-group — Sequential Group Distillation

Purpose: Run /xia rounds against a ranked list of repos, using the codebase itself as the running distillation. Each round absorbs only what the previous rounds haven't already covered.

Core rule: You never compare two external repos directly. The codebase is always side A. Each round updates A before the next comparison begins.


Usage

/xia-group <group-name> <repo1> <repo2> ... [--focus <topic>]
  • <group-name>: label for this group run (e.g. autonomous-loops)
  • <repo1> <repo2> ...: repos in order — richest/most complex first, simplest last
  • --focus <topic>: optional, passed to each /xia round as its focus

Example:

/xia-group autonomous-loops ralph-claude-code ralphex ralphy sleepless-agent claude-auto-resume --focus loop

Storage

Group state is stored alongside xia patterns:

<project-root>/
└── .claude/
    └── xia/
        ├── XIALOGUE.md
        ├── groups/
        │   └── xia-group-[name].md   ← group progress file
        └── patterns/
            └── xia-[repo-slug]-[pattern].md

Ordering Rule

Before running any round, sort the repo list:

  1. Richest/most complex first (most patterns, highest token count)
  2. Simplest/most specific last

Rationale: by round N, the simple repos will mostly register as "already covered" — which is the signal that distillation is working.


Phase G0 — Group Init

Commands:

# 1. Check for prior group state
cat .claude/xia/groups/xia-group-$GROUP_NAME.md 2>/dev/null || echo "GROUP_MISSING"
# 2. Check prior XIALOGUE state
cat .claude/xia/XIALOGUE.md 2>/dev/null || echo "XIALOGUE_MISSING"

If GROUP_MISSING, create .claude/xia/groups/xia-group-[name].md with this exact structure:

# Group: [name]
**Focus:** [focus or "none"]
**Started:** [YYYY-MM-DD]

## Round Log

| Round | Repo | Status | Borrowed | Already Covered | Skipped |
|-------|------|--------|----------|-----------------|---------|

## Remaining
[ordered repo list, one per line]

Read the full file on GitHub · 210 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. 6d ago First seen · 210 lines · 25 tokens per session scan B 445b95f4bcb4

Subscribe to this mod's changes

xia-group is a command published in the GitHub repository spideynolove/claude-dotfiles (2 stars, last pushed 3mo ago), licensed MIT. It adds 25 tokens to every session and 1,435 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.