convex-retention

convex-retention is a skill for Claude Code, Codex from openclaw/clawhub. It costs 40 tokens per session (405 once invoked), scanned A, original, MIT.

A retention-policy workflow for Convex database tables, defining how long temporary data stays and how expired records are cleaned up.

In plain words
What is it for?
Use it when adding or changing tables, expiry fields, cleanup jobs, authentication or session cleanup, duplicate-metric cleanup, or removal of deprecated tables.
Why use it?
It prevents short-lived data from accumulating and ensures new tables have an explicit, bounded cleanup path.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

Good fit Use it when adding or changing tables, expiry fields, cleanup jobs, authentication or session cleanup, duplicate-metric cleanup, or removal of deprecated tables.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/openclaw/clawhub/convex-retention
About the project

ClawHub is a public registry where OpenClaw users publish, version, search, and install text-based agent skills and OpenClaw packages. It provides web browsing, a CLI-oriented API, moderation, vector search, and artifact hosting for code plugins, bundle plugins, and experimental whole-agent packages. The catalogue skills and agents are entries that can be discovered or used through this registry.

openclaw/clawhub · 9,402 stars · on GitHub · clawhub.ai

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 openclaw/clawhub --skill convex-retention
Clone the repo
git clone --depth 1 https://github.com/openclaw/clawhub

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 convex-retention

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

Your own site · 80×15
<a href="https://agentmods.dev/skills/openclaw/clawhub/convex-retention"><img src="https://agentmods.dev/badge/skills/openclaw/clawhub/convex-retention.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 40 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 405 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.00040 $0.00405
Opus 5 $0.00020 $0.00202
Sonnet 5 $0.00008 $0.00081
Haiku 4.5 $0.00004 $0.00040

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

Security

Grade A, and why

convex-retention 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 9d 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.

.agents/skills/convex-retention/SKILL.md · 36 lines

What it actually says

Convex Retention

Overview

ClawHub retention is code-owned. Every current Convex table must be classified in convex/lib/retentionPolicy.ts, and ephemeral tables need an indexed, bounded cleanup path unless their lifecycle is handled by usage-time validation or a documented component.

Checklist

  • Use clawhub-convex and read convex/_generated/ai/guidelines.md first.
  • Add every new schema table to RETENTION_POLICIES; the Record<TableNames, RetentionPolicy> type is the enforcement gate.
  • For ephemeral tables, prefer an explicit expiration field plus index, then prune with .withIndex() and .take(...).
  • For new generic TTL tables, prefer expirationTime to match Convex Auth. Keep existing expiresAt, dayStart, and processedAt fields unless that table already needs a real migration.
  • Use RETENTION_STANDARD_BATCH_SIZE for ordinary retention jobs. Keep incident-tested special cases, such as skillStatEvents, on their documented caps.
  • Cron jobs should schedule bounded cleanup entrypoints only. Large one-off production migrations or destructive backfills still start with convex-migration-helper.
  • Do not bulk-clear active auth state. Expired authSessions and authRefreshTokens are pruned by convex/retention.ts.

Verification

  • Add or update focused tests for policy classification and cleanup behavior.
  • Run the focused Vitest slice for touched cleanup modules.
  • Run bunx convex codegen after schema/API changes.
  • Run a real Convex runtime check such as bunx convex dev --once --typecheck=disable.
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. 9d ago First seen · 36 lines · 40 tokens per session scan A b251d92127e3

Subscribe to this mod's changes

convex-retention is a skill published in the GitHub repository openclaw/clawhub (9,402 stars, last pushed yesterday), licensed MIT. It adds 40 tokens to every session and 405 once invoked, about $0.0002 per session on Opus 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

Other skills, from other repositories

architect/data-api-design

A guide to designing data models and application programming interfaces (APIs), which are the rules software uses to exchange data.

echoVic/boss-skill · 26 tokens

directory-based-skill

A skill loaded from a directory structure with SKILL.md frontmatter, plus file-based and URL-based instruction sources.

agentfront/frontmcp · 28 tokens

ask-zilliz

Zilliz Cloud onboarding and usage assistant. Helps users understand Zilliz Cloud, choose the right plan, estimate costs, write code, debug issues, and adopt new features like Functions, Volumes, and Global Clusters. Use this skill whenever the user asks about Zilliz Cloud — including plan selection, pricing, cost…

zilliztech/zilliz-plugin · 236 tokens

acl

Use when the user wants to manage Zilliz Cloud access control -- custom org or project roles and their policies, granting or revoking a role for an organization member, or binding roles to a SCIM user group. This is cloud-level RBAC over organizations, projects, and clusters -- for database users and privileges inside…

zilliztech/zilliz-plugin · 74 tokens

diagnose

Use when the user reports that a Zilliz Cloud cluster or Milvus collection is unhealthy, slow, stuck, returning errors, hitting quotas, or otherwise misbehaving — or when they ask "what's wrong with...", "why is ... slow", "diagnose ...", "troubleshoot ...".

zilliztech/zilliz-plugin · 65 tokens

collection

Use when the user wants to create, list, describe, drop, rename, load, release, or manage collections and collection aliases in Milvus.

zilliztech/zilliz-plugin · 32 tokens