self-map

self-map is a skill for Claude Code, Codex from smixs/iva-agent. It costs 85 tokens per session (4,235 once invoked), scanned A, original, MIT.

A set of instructions for tracing an AI assistant's own turns, events, failures, logs, schedules, and usage data. It explains how to follow an event back to its cause and identify who or what owns the problem.

In plain words
What is it for?
Use it to investigate failed turns, inspect traces and service journals, check usage data, and report what happened and why.
Why use it?
It prevents diagnosis from relying on incomplete memory and avoids unsafe commands that could restart services or change state. It also limits large log reads to the relevant failure details.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions subagents; positional $N argument.

Good fit Use it to investigate failed turns, inspect traces and service journals, check usage data, and report what happened and why.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/smixs/iva-agent/self-map
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.

Any agent
npx skills add smixs/iva-agent --skill self-map
Clone the repo
git clone --depth 1 https://github.com/smixs/iva-agent

Made for: Claude Code, Codex.

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 self-map

README.md
[![agentmods](https://agentmods.dev/badge/skills/smixs/iva-agent/self-map/github.svg)](https://agentmods.dev/skills/smixs/iva-agent/self-map)
Your own site
<a href="https://agentmods.dev/skills/smixs/iva-agent/self-map"><img src="https://agentmods.dev/badge/skills/smixs/iva-agent/self-map/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for self-map

Your own site · 80×15
<a href="https://agentmods.dev/skills/smixs/iva-agent/self-map"><img src="https://agentmods.dev/badge/skills/smixs/iva-agent/self-map.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 85 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,235 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.00085 $0.04235
Opus 5.5 $0.00034 $0.01694
Sonnet 5.5 $0.00017 $0.00847
Haiku 4.5 $0.00009 $0.00424

Measured 1mo ago against content hash 53bcdbe57c32, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

self-map 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 1mo 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.

agent/skills/self-map/SKILL.md · 283 lines

How it starts

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

Self-map

Paths are relative to the bash folder — the running Version (~/iva/versions/<v>; ~/iva/current points at it). Your own code is here, not in ~/iva. Data is $ASSISTANT_DATA_DIR (default ./data). Everything below is for inspection unless the owner requests a repair.

Keep the output small

bash gives you only the last 30 000 characters of each stream; read_file stops at 24 000. Never cat a day file of the Trace or data/usage.jsonl: they run to megabytes. A long turn — print only what is around its failures:

iva trace show <session>/<turn> | grep -B4 -A2 -e 'failure=' -e 'turn.failed' -e 'step.failed'

Commands in a turn

Only one lifecycle command is accepted at a time; read its result before requesting another.

  • iva doctor in a turn prints the complete read-only diagnosis; repairs belong to the owner in a terminal.
  • Перезапуск, обновление, откат — только iva <глагол>: он сам отложит действие до конца хода; systemctl/launchctl/pkill по Иве из хода убивают ответ.
  • iva diagnose — read-only; in a turn only through report-problem.
  • iva logs, iva trace tail — they follow forever and end only on the bash timeout. Use journalctl … --no-pager -n N and iva trace show.
  • iva proactive on|off|set, iva jobs ack — they change state; only on the owner's word.

One turn = session + turn

turn_N starts again at turn_0 in every session, so a turn is named by both: <session>/<turn>, for example wrun_01M43YEKCW0FRANBS1E510CWX5/turn_0. Nobody tells you your own session; find the turn from what you have:

  • A line of the failure list in your prompt — it ends with the command; run it.
  • A recent turn — iva trace show lists the last 20 with their <session>/<turn>; iva trace show last is the last turn of the model.
  • A chat message — iva trace show tg:<chat>:<message>.
  • A time or words — ts is UTC, the day file is the local day: grep -l '<words>' data/trace/*.jsonl, then grep -h '<words>' data/trace/<day>.jsonl | cut -c1-200 shows turn and session.

Read the full file on GitHub · 283 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. 1mo ago Changed · +23 lines 53bcdbe57c32
  2. 1mo ago Changed · +8 lines 3845615fef55
  3. 1mo ago Changed · +64 lines · +3 tokens per session 7705bffedb4b
  4. 1mo ago First seen · 188 lines · 82 tokens per session scan A c8b7dd331e83

Subscribe to this mod's changes

self-map is a skill published in the GitHub repository smixs/iva-agent (314 stars, last pushed 3d ago), licensed MIT. It adds 85 tokens to every session and 4,235 once invoked, about $0.0003 per session on Opus 5.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-10-09.

Related

self-map compared with skills from other repositories

self-map next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
self-mapsmixs/iva-agentSkill3143d agoMITA85Claude Code, Codex
systematic-debuggingmoltis-org/moltisSkill3.0k1mo agoMITA33Claude Code, Codex
alert-sopPM-Shawn/Abu-CoworkSkill426yesterdayApache-2.0A20Claude Code
code-reviewAlex8791-cyber/cognithorSkill1567d agoApache-2.0A13Claude Code, Codex
regexbug-ops/zephSkill68yesterdayMITA85Claude Code, Codex
code-analysisbug-ops/zephSkill68yesterdayMITA105Claude Code, Codex
networkbug-ops/zephSkill68yesterdayMITA83Claude Code, Codex