letta-ai/letta-code is an agent harness for building assistants that retain memory, identity, and experience across interactions instead of treating each task as isolated. Developers use it through local, desktop, browser, or messaging interfaces for interactive or continuously running agents, and its catalogue entries configure the agents' skills, instructions, rules, and behavior.
Borrowing it
Nothing to install: this file belongs to letta-ai/letta-code. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/letta-ai/letta-code/main/.skills/adding-models/SKILL.mdgit clone --depth 1 https://github.com/letta-ai/letta-codeWrote 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.
[](https://agentmods.dev/skills/letta-ai/letta-code/adding-models)<a href="https://agentmods.dev/skills/letta-ai/letta-code/adding-models"><img src="https://agentmods.dev/badge/skills/letta-ai/letta-code/adding-models/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.
<a href="https://agentmods.dev/skills/letta-ai/letta-code/adding-models"><img src="https://agentmods.dev/badge/skills/letta-ai/letta-code/adding-models.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector warn
SkillSpector: 3 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 Excessive Agency · line 83 Skill selects an external model or provider that may use a different account or billing plan than the operator expects. Undisclosed model switches can cause unexpected cost or quota consumption.Fix: Remove the model/provider override or disclose it prominently and require explicit operator approval before invoking an external coding CLI or billed model.
- medium Data Exfiltration · line 40 Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.Fix: Verify the destination URL is trusted and necessary. Remove or replace with documented APIs. Ensure no secrets, tokens, or PII are transmitted.
- medium Data Exfiltration · line 47 Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.Fix: Verify the destination URL is trusted and necessary. Remove or replace with documented APIs. Ensure no secrets, tokens, or PII are transmitted.
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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00058 | $0.01025 |
| Opus 5.5 | $0.00023 | $0.00410 |
| Sonnet 5.5 | $0.00012 | $0.00205 |
| Haiku 4.5 | $0.00006 | $0.00103 |
Grade A, and why
adding-models scanned grade A 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 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.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
curl -s https://api.letta.com/v1/models/catalog | jq '.models[] | [.id, .handle]' How it starts
The opening of the file, as written. The whole thing — 109 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Adding Models
This skill guides you through adding a new LLM model to Letta Code.
Quick Reference
Key files:
src/agent/remote-model-catalog.ts- Runtime catalog loading and projectionsrc/agent/model-catalog.ts- Model lookup and compatibility aliases.github/workflows/ci.yml- CI test matrix (optional)src/tools/manager.ts- Toolset detection logic (rarely needed)
Workflow
Step 1: Find Valid Model Handles
First identify the agent source. These inputs are deliberately different:
| Agent source | Rows shown | Labels, presets, and capabilities |
|---|---|---|
| Cloud hosted | GET /v1/models/catalog only |
GET /v1/models/catalog |
| Cloud organization BYOK | BYOK rows from GET /v1/models |
Match to catalog metadata using provider metadata and model name; retain the BYOK handle for selection |
| Local | pi-ai inventory | pi-ai metadata |
| Custom App Server | Server runtime inventory | Server runtime metadata |
In Cloud mode, never use base/hosted rows from GET /v1/models to filter,
supplement, delay, or provide a fallback for the hosted catalog. This once made
GPT-4o appear in a selector even though the Cloud catalog deliberately omitted
it. GET /v1/models remains necessary for organization-specific BYOK rows.
Query the Cloud hosted catalog to see hosted preset IDs, handles, and capabilities:
curl -s https://api.letta.com/v1/models/catalog | jq '.models[] | [.id, .handle]'
To inspect organization BYOK rows from a Cloud backend, query its model
inventory and filter by provider_category:
curl -s https://api.letta.com/v1/models/ \
| jq '.[] | select(.provider_category == "byok") | [.handle, .provider_type]'
Do not use this response as a second hosted catalog.
Common provider prefixes:
anthropic/- Claude modelsopenai/- GPT modelsgoogle_ai/- Gemini modelsgoogle_vertex/- Vertex AIopenrouter/- Various providers
Step 2: Update the Owning Catalog
Letta Code does not bundle a model catalog:
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.
- 1mo ago Changed · +16 lines d1b63c141aaf
- 2mo ago First seen · 93 lines · 58 tokens per session scan A 2e241d749070
adding-models is a skill published in the GitHub repository letta-ai/letta-code (3,730 stars, last pushed today), licensed Apache-2.0. It adds 58 tokens to every session and 1,025 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
kv-cache-design
A guide to arranging an AI agent's conversation so previously processed text can be reused. A KV cache stores intermediate results for earlier tokens, while a prompt cache reuses a stable beginning across requests.
reward-design
A guide to defining the scores that an AI agent receives during trial-and-error training. It covers checks based on rules, human preferences, or another model, and distinguishes rewarding the final result from rewarding the steps taken.
post-training-strategy
A guide to choosing and planning ways to improve an AI model after its initial training. It explains when to add knowledge, teach a response format, use trial-and-error training, or use a smaller model to learn from a larger one.
agent-evolution
A guide to making an AI agent improve from its past runs. It covers how to judge results, extract reusable lessons, and decide whether to store them as knowledge, instructions, code, or model training.
bad-case-to-dpo
A guide to turning failed production agent runs into training and evaluation data. It explains how to find the first mistake, create preference examples for DPO (Direct Preference Optimization), and check that a fix does not damage other tasks.
knowledge-org
A guide to organising large bodies of knowledge so an AI system can navigate relationships, summaries, and layers instead of searching only flat text chunks. It covers tree indexes, knowledge graphs, file-like structures, incremental updates, and long-term memory layouts.