loop

loop is a skill for Claude Code, Codex from XiaomiMiMo/MiMo-Code. It costs 101 tokens per session (1,594 once invoked), scanned A, original, MIT.

A scheduling skill that runs a prompt repeatedly on a fixed timetable. A prompt is the instruction given to the coding agent.

In plain words
What is it for?
Use it to run an instruction immediately and then repeat it every specified number of seconds, minutes, hours, or days.
Why use it?
It removes the need to remember and start the same check or task manually at regular intervals.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to run an instruction immediately and then repeat it every specified number of seconds, minutes, hours, or days.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/xiaomimimo/mimo-code/loop
About the project

MiMoCode is a terminal-based AI coding assistant that reads and writes code, runs commands, manages Git, and remembers project context across sessions. Developers use it to work with software projects through a command-line interface and connect it to language-model providers; the catalogue includes skills and instructions for it.

XiaomiMiMo/MiMo-Code · 13,799 stars · on GitHub · mimo.xiaomi.com

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 XiaomiMiMo/MiMo-Code --skill loop
Clone the repo
git clone --depth 1 https://github.com/XiaomiMiMo/MiMo-Code

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 loop

README.md
[![agentmods](https://agentmods.dev/badge/skills/xiaomimimo/mimo-code/loop/github.svg)](https://agentmods.dev/skills/xiaomimimo/mimo-code/loop)
Your own site
<a href="https://agentmods.dev/skills/xiaomimimo/mimo-code/loop"><img src="https://agentmods.dev/badge/skills/xiaomimimo/mimo-code/loop/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 loop

Your own site · 80×15
<a href="https://agentmods.dev/skills/xiaomimimo/mimo-code/loop"><img src="https://agentmods.dev/badge/skills/xiaomimimo/mimo-code/loop.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 101 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,594 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
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.00101 $0.01594
Opus 5.5 $0.00040 $0.00638
Sonnet 5.5 $0.00020 $0.00319
Haiku 4.5 $0.00010 $0.00159

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

Security

Grade A, and why

loop 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 2mo 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.

packages/cli/src/skill/builtin/.bundle/loop/SKILL.md · 83 lines

How it starts

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

/loop — schedule a recurring prompt

This skill turns a free-form [interval] <prompt> line into a cron tool call and runs the prompt once right away.

1. Parse the input

The user's text is whatever appears after /loop . Apply the three rules below in order and stop at the first match.

  1. Leading interval token. If the first whitespace-separated token matches the regex ^\d+[smhd]$ (case-insensitive), that token is the interval. Examples: 5m, 2h, 1d, 30s. The rest of the input is the prompt.

  2. Trailing every <N><unit> clause. Otherwise, look for a clause at the end of the input of the form every <N><unit> or every <N> <unit-word> where <unit> is s|m|h|d and <unit-word> is second(s)|minute(s)|hour(s)|day(s). Strip the clause; what's left is the prompt; the captured <N><unit> is the interval. Examples: every 20m, every 5 minutes, every 2 hours.

  3. Default. No interval found → interval is 10m, the whole input is the prompt.

If the input is empty, or is only an interval with no prompt body, reply with a one-line usage hint (/loop [interval] <prompt>) and stop. Do not schedule anything.

2. Special: empty prompt with autonomous opt-in

When the user types /loop <interval> (interval only) and the project has explicitly opted into autonomous-loop mode (a session-level flag the runtime sets), the prompt body is the sentinel <<autonomous-loop>>. The scheduler expands this sentinel at fire time into a self-directed tick instruction. If autonomous mode is not enabled, treat empty as the usage-hint case above.

3. Map interval → 5-field cron expression

Pattern Cron expression
Ns treat as ceil(N/60)m; minimum is 1m
Nm where N is 1–59 and divides cleanly (1, 2, 3, 4, 5, 6, 10, 12, 15, 20, 30) */N * * * *
Nm where N ≥ 60 and N/60 divides 24 (1, 2, 3, 4, 6, 8, 12) 0 */(N/60) * * *
Nh where N is 1–23 and divides 24 0 */N * * *
Nd where N divides 31 sensibly (1, 2) 0 0 */N * *

Read the full file on GitHub · 83 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. 2mo ago Changed · +3 lines de15370ea281
  2. 3mo ago First seen · 80 lines · 101 tokens per session scan A 1d74c9a1c575

Subscribe to this mod's changes

loop is a skill published in the GitHub repository XiaomiMiMo/MiMo-Code (13,799 stars, last pushed yesterday), licensed MIT. It adds 101 tokens to every session and 1,594 once invoked, about $0.0004 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-08-30.

Related

loop compared with skills from other repositories

loop next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
loopXiaomiMiMo/MiMo-CodeSkill14kyesterdayMITA101Claude Code, Codex
obsidian-baseskepano/obsidian-skillsSkill55k4d agoMITA63Claude Code
gws-calendargoogleworkspace/cliSkill33k6d agoApache-2.0A12Claude Code, Codex
gws-gmail-sendgoogleworkspace/cliSkill33k6d agoApache-2.0A13Claude Code, Codex
gws-gmail-watchgoogleworkspace/cliSkill33k6d agoApache-2.0A20Claude Code, Codex
gws-gmailgoogleworkspace/cliSkill33k6d agoApache-2.0A16Claude Code, Codex
recipe-create-vacation-respondergoogleworkspace/cliSkill33k6d agoApache-2.0A25Claude Code, Codex