agent-identity

agent-identity is a skill for Claude Code, Codex from JKHeadley/instar. It costs 0 tokens per session (1,575 once invoked), scanned B, original, MIT.

A set of project files that gives a coding agent a name, role, working preferences, and memory across sessions.

In plain words
What is it for?
It helps configure how the agent behaves, record who it works with, and preserve lessons learned between sessions.
Why use it?
It prevents the agent from starting with no context each time and losing important information during long sessions.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions CLAUDE.md; mentions Claude Code.

Good fit It helps configure how the agent behaves, record who it works with, and preserve lessons learned between sessions.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/jkheadley/instar/agent-identity
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 JKHeadley/instar --skill agent-identity
Clone the repo
git clone --depth 1 https://github.com/JKHeadley/instar

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 agent-identity

README.md
[![agentmods](https://agentmods.dev/badge/skills/jkheadley/instar/agent-identity.svg)](https://agentmods.dev/skills/jkheadley/instar/agent-identity)
Your own site
<a href="https://agentmods.dev/skills/jkheadley/instar/agent-identity"><img src="https://agentmods.dev/badge/skills/jkheadley/instar/agent-identity.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,575 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. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 5 findings, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Agent Snooping · line 159
    Skill reads from agent configuration directories (.claude/, .codex/, .gemini/). These directories may contain API keys, personal settings, and other credentials that the skill has no legitimate need to access.
    Fix: Remove all code or instructions that access agent configuration directories (.claude/, .codex/, .gemini/). If configuration values are needed, pass them explicitly as parameters or environment variabl
  • high Agent Snooping · line 160
    Skill reads from agent configuration directories (.claude/, .codex/, .gemini/). These directories may contain API keys, personal settings, and other credentials that the skill has no legitimate need to access.
    Fix: Remove all code or instructions that access agent configuration directories (.claude/, .codex/, .gemini/). If configuration values are needed, pass them explicitly as parameters or environment variabl
  • high Agent Snooping · line 161
    Skill reads from agent configuration directories (.claude/, .codex/, .gemini/). These directories may contain API keys, personal settings, and other credentials that the skill has no legitimate need to access.
    Fix: Remove all code or instructions that access agent configuration directories (.claude/, .codex/, .gemini/). If configuration values are needed, pass them explicitly as parameters or environment variabl
  • high Agent Snooping · line 178
    Skill reads from agent configuration directories (.claude/, .codex/, .gemini/). These directories may contain API keys, personal settings, and other credentials that the skill has no legitimate need to access.
    Fix: Remove all code or instructions that access agent configuration directories (.claude/, .codex/, .gemini/). If configuration values are needed, pass them explicitly as parameters or environment variabl
  • medium MCP Rug Pull · line 223
    npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.
    Fix: Pin the version: npx @scope/[email protected]
How audits are shown
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.00000 $0.01575
Opus 5 $0.00000 $0.00788
Sonnet 5 $0.00000 $0.00315
Haiku 4.5 $0.00000 $0.00158

Measured 8d ago against content hash c30d1978501c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade B, and why

agent-identity 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 8d 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/identity/AGENT.md
skills/agent-identity/SKILL.md · 227 lines

How it starts

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

agent-identity — Persistent Agent Identity for Claude Code

Without identity infrastructure, every Claude Code session starts from zero. The agent has no name, no remembered preferences, no sense of who it works with or what it has learned. Context compaction erases everything mid-session. This skill fixes that — no external tools required.

What This Skill Creates

Three files at .claude/identity/:

  • AGENT.md — Who the agent is: name, role, personality, principles
  • USER.md — Who the agent works with: preferences, context, communication style
  • MEMORY.md — What the agent has learned across sessions

And a reference in CLAUDE.md that teaches the agent to read them at every session start.


Step 1: Create the Identity Directory

mkdir -p .claude/identity

Step 2: Create AGENT.md

Replace the placeholder values with your actual agent name and role.

# [Agent Name]

## Who I Am

I am [Agent Name], the autonomous agent for [Project Name]. I handle [main
responsibilities] and work alongside my collaborator.

## Role

[One sentence on what this agent does.]

## Personality

[Describe how the agent should behave: tone, directness, initiative level.]

## My Principles

1. Build, don't describe — implement, don't list options.
2. Follow through to done — code is done when it's running, not when it compiles.
3. Write to MEMORY.md — when I learn something worth keeping, I write it down.
4. Be honest about limits — fabricating certainty is worse than admitting uncertainty.
5. Act, don't ask — only pause for destructive or genuinely ambiguous decisions.

## Who I Work With

My primary collaborator is [User Name]. They prefer [communication style].
They value [what they value]. See USER.md for full context.

Save to .claude/identity/AGENT.md.


Step 3: Create USER.md

# [User Name]

## About

[Brief description — role, relationship to this project.]

## Communication Preferences

- [Preference 1: e.g., "Direct answers over long explanations"]
- [Preference 2: e.g., "Proactive updates, not requests for permission"]
- [Preference 3: e.g., "Summaries via Telegram, not just files"]

## Working Style

[How they like to work, what they find frustrating, what they value.]

## Notes

Update this file as you learn more about [User Name]'s preferences.

Read the full file on GitHub · 227 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. 8d ago First seen · 227 lines · 0 tokens per session scan B c30d1978501c

Subscribe to this mod's changes

agent-identity is a skill published in the GitHub repository JKHeadley/instar (79 stars, last pushed today), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,575 tokens. 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-30.