convex-performance-audit
Screenshots
Installation
Review the source and dependencies with a prompt. A package is available to download.
Install with an AI assistant
Copy the prompt so your assistant can review the pinned revision and dependencies first.
View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "convex-performance-audit" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-3b5ed5d826400d6c135383d4d2623d9439a97c0b1d9a5072a55746a387884515. Verify the upstream source and version against https://github.com/openclaw/clawhub before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.
Source and setup
github.com
Setup guidance pending
See the original source for supported tools, dependencies, and permissions.
Installation test pending
An audit of Convex performance for reads, subscriptions, write contention, and function limits. Intended to diagnose slow-running functions, insight discovery issues, OCC conflicts, or read amplification.
Introduction source: third_party · openclaw · 0.0.1 Reference
SkillPi interpretation
- Tasks
- Audits Convex performance for reads, subscriptions, write contention, and
- Audience
- A Convex page or feature feels slow or expensive `npx convex insights --details` reports high bytes read, documents read, or OCC conflicts Low-freshness read paths are using reactivity where point-in-time reads would do OCC conflict errors or excessive mutation retries High subscription count or slow UI updates Functions approaching execution or transaction limits The same performance pattern needs fixing across sibling functions
- Inputs and outputs
- Not specified in the source documentation.
- Software, accounts and paid services
- Not specified in the source documentation.
- Limits and differences
- Not specified in the source documentation.
- Testing
- Not tested
Browse files
Frontmatter
name: convex-performance-audit
description: Audits Convex performance for reads, subscriptions, write contention, and
function limits. Use for slow features, insights findings, OCC conflicts, or
read amplification.Convex Performance Audit
Diagnose and fix performance problems in Convex applications, one problem class at a time.
When to Use
- A Convex page or feature feels slow or expensive
npx convex insights --detailsreports high bytes read, documents read, or OCC conflicts- Low-freshness read paths are using reactivity where point-in-time reads would do
- OCC conflict errors or excessive mutation retries
- High subscription count or slow UI updates
- Functions approaching execution or transaction limits
- The same performance pattern needs fixing across sibling functions
When Not to Use
- Initial Convex setup, auth setup, or component extraction
- Pure schema migrations with no performance goal
- One-off micro-optimizations without a user-visible or deployment-visible problem
Guardrails
- Prefer simpler code when scale is small, traffic is modest, or the available signals are weak
- Do not recommend digest tables, document splitting, fetch-strategy changes, or migration-heavy rollouts unless there is a measured signal, a clearly unbounded path, or a known hot read/write path
- In Convex, a simple scan on a small table is often acceptable. Do not invent structural work just because a pattern is not ideal at large scale
First Step: Gather Signals
Start with the strongest signal available:
- If deployment Health insights are already available from the user or the current context, treat them as a first-class source of performance signals.
- If CLI insights are available, run
npx convex insights --details. Use--prod,--preview-name, or--deployment-namewhen needed.- If the local repo's Convex CLI is too old to support
insights, trynpx -y convex@latest insights --detailsbefore giving up.
- If the local repo's Convex CLI is too old to support
- If the repo already uses
convex-doctor, you may treat its findings as hints. Do not require it, and do not treat it as the source of truth. - If runtime signals are unavailable, audit from code anyway, but keep the guardrails above in mind. Lack of insights is not proof of health, but it is also not proof that a large refactor is warranted.
Signal Routing
After gathering signals, identify the problem class and read the matching reference file.
| Signal | Reference |
|---|---|
| High bytes or documents read, JS filtering, unnecessary joins | references/hot-path-rules.md |
| OCC conflict errors, write contention, mutation retries | references/occ-conflicts.md |
| High subscription count, slow UI updates, excessive re-renders | references/subscription-cost.md |
| Function timeouts, transaction size errors, large payloads | references/function-budget.md |
| General "it's slow" with no specific signal | Start with references/hot-path-rules.md |
Multiple problem classes can overlap. Read the most relevant reference first, then check the others if symptoms remain.
Escalate Larger Fixes
If the likely fix is invasive, cross-cutting, or migration-heavy, stop and present options before editing.
Examples:
- introducing digest or summary tables across multiple flows
- splitting documents to isolate frequently-updated fields
- reworking pagination or fetch strategy across several screens
- switching to a new index or denormalized field that needs migration-safe rollout
When correctness depends on handling old and new states during a rollout,
consult the convex-migration-helper skill for the migration workflow.
Workflow
1. Scope the problem
Pick one concrete user flow from the actual project. Look at the codebase, client pages, and API surface to find the flow that matches the symptom.
Write down:
- entrypoint functions
- client callsites using
useQuery,usePaginatedQuery, oruseMutation - tables read
- tables written
- whether the path is high-read, high-write, or both
2. Trace the full read and write set
For each function in the path:
- Trace every
ctx.db.get()andctx.db.query() - Trace every
ctx.db.patch(),ctx.db.replace(), andctx.db.insert() - Note foreign-key lookups, JS-side filtering, and full-document reads
- Identify all sibling functions touching the same tables
- Identify reactive stats, aggregates, or widgets rendered on the same page
In Convex, every extra read increases transaction work, and every write can invalidate reactive subscribers. Treat read amplification and invalidation amplification as first-class problems.
3. Apply fixes from the relevant reference
Read the reference file matching your problem class. Each reference includes specific patterns, code examples, and a recommended fix order.
Do not stop at the single function named by an insight. Trace sibling readers and writers touching the same tables.
4. Fix sibling functions together
When one function touching a table has a performance bug, audit sibling functions for the same pattern.
After finding one problem, inspect both sibling readers and sibling writers for the same table family, including companion digest or summary tables.
Examples:
- If one list query switches from full docs to a digest table, inspect the other list queries for that table
- If one mutation isolates a frequently-updated field or splits a hot document, inspect the other writers to the same table
- If one read path needs a migration-safe rollout for an unbackfilled field, inspect sibling reads for the same rollout risk
Do not leave one path fixed and another path on the old pattern unless there is a clear product reason.
5. Verify before finishing
Confirm all of these:
- Results are the same as before, no dropped records
- Eliminated reads or writes are no longer in the path where expected
- Fallback behavior works when denormalized or indexed fields are missing
- Frequently-updated fields are isolated from widely-read documents where needed
- Every relevant sibling reader and writer was inspected, not just the original function
Reference Files
references/hot-path-rules.md- Read amplification, invalidation, denormalization, indexes, digest tablesreferences/occ-conflicts.md- Write contention, OCC resolution, hot document splittingreferences/subscription-cost.md- Reactive query cost, subscription granularity, point-in-time readsreferences/function-budget.md- Execution limits, transaction size, large documents, payload size
Also check the official Convex Best Practices page for additional patterns covering argument validation, access control, and code organization that may surface during the audit.
Checklist
- [ ] Gathered signals from insights, dashboard, or code audit
- [ ] Identified the problem class and read the matching reference
- [ ] Scoped one concrete user flow or function path
- [ ] Traced every read and write in that path
- [ ] Identified sibling functions touching the same tables
- [ ] Applied fixes from the reference, following the recommended fix order
- [ ] Fixed sibling functions consistently
- [ ] Verified behavior and confirmed no regressions
Version history
-
v0.27.0
GitHub ↗
Original release notes
## 0.27.0 - 2026-11-17 - Scan reports: `clawhub scan download <skill> --version <version>` now returns a report when a skill version's publication checks failed before a verdict. It used to answer "Scan results not found". The archive says the scan failed with no safety verdict, lists the check states and whether a retry is waiting, and says to remove Python bytecode when that stopped the scan. Worker errors are not included. Plugin versions are unchanged. - CLI: add `clawhub skill publication <skill> --version <version>`. It prints the owner-only publication stage for that exact skill version, including whether a retry is already waiting and how to download a stored scan report. A completed publication does not claim the skill is currently visible. - Package publish: a missing uploaded package tarball is a client error. The message stays "Package tarball upload no longer exists". - Skill reads: a missing stored skill file is a client error for the readme, skill card, file text, and publish preview text. The message stays "File missing in storage". - Catalog: keep package search versions aligned with the current release when editing metadata on packages with stale version summaries. Package mutations now rely on the shared trigger to refresh search projections. - Skill publish: a bad upload ticket is a client error. The messages stay "Skill upload ticket is missing, used, or expired", "Uploaded file does not match its skill upload ticket", and "Skill upload ticket does not match this publish". - Scanning: reuse the shared subprocess runner for legacy pre-publication scanners, bounding captured output to 32 MiB stdout and 1 MiB stderr while preserving scanner verdict exit codes. ### Release Proof - npm: https://www.npmjs.com/package/clawhub/v/0.27.0 - tarball: https://registry.npmjs.org/clawhub/-/clawhub-0.27.0.tgz - integrity: sha512-C8iIFtKZ2s2b8lS8LL70aDkYAzZ0Q1W4P816shyFz80gm4FJe2J3Df+Y7NqooryR7N6nuL5V7uPf+3QXorKsbQ== - npm preflight: https://github.com/openclaw/clawhub/actions/runs/44250634360 - npm publish: https://github.com/openclaw/clawhub/actions/runs/44251605577
-
v0.26.0
GitHub ↗
Original release notes
## 0.26.0 - 2026-11-12 - Templates: accept native agent settings, including `agent.tools`, and top-level `skills` and `plugins` dependencies in `CLAW.md`. Dependencies can reference exact ClawHub versions or bundled package directories. This fixes the stable CLI rejecting the supported Template format before upload (#4551). Publish an already-built `.tgz`; successful publication does not establish compatibility with a particular OpenClaw consumer release. - CLI: add `clawhub package publication <name> --version <version>`. It prints whether that exact version is published, still pending, failed, or was never accepted. The public version list hides a pending release, and `package readiness` remains the official-migration check. Older registries that answer the publication URL with a version document or 404 are checked through the version endpoint. A failed attempt says an authorized publisher may recover it with `package recover` and a reason. - Publishing: run reusable package-publish plugin validation with Node.js 24. The CLI refuses `package validate` under Bun, so the workflow builds the pinned CLI and runs `node packages/clawhub/bin/clawdhub.js package validate`. - CLI login: the device page no longer fills the approval code from the link. Type the code from the terminal. The page shows the token label and that approval creates a full API token. A scope other than `read write` is rejected. Authorize and Deny turn off when the code's expiry time passes, including when the page was already open before the code was typed, and the pending query does not read the clock. Expired, used, and mistyped codes say how to continue, and a finished approval no longer shows the code as already used. - CI: verify and cache a pinned Convex backend through the release-asset API before local-auth browser tests, with bounded download retries. - CLI: keep a saved API token on the registry that issued it. A `--site` well-known document cannot send that token to another origin, and it does not replace the saved login, including a legacy `auth.clawhub.ai` registry. Discovered registry URLs must be `http` or `https` and must not contain userinfo. `clawhub-admin` commands follow the same rule. - Skills: recognize a single top-level `env` name as a required variable so installation guidance and scanner metadata retain the declared credential. - CLI: on Bun, send the API token to curl on stdin instead of the command line. JSON, form, text, download, and binary upload requests use the same header stdin path. - API: return one publish-token rejection when a package is missing, hidden, or the GitHub identity does not match, without naming the trusted repository. The body tells the caller to ask a package manager to check the trusted-publisher configuration and the workflow OIDC claims. A GitHub signing-key outage answers a retryable `503` instead of a rejection. - CI: right-size Skill Card workers and credential canaries to two-vCPU runners, retaining four-vCPU skill evaluations and existing resource checks. - CLI: explain a missing npm when packing a package folder. On Windows, packing runs the installed npm directly, so a package folder cannot substitute its own `npm.cmd`. Other platforms keep the normal `npm` lookup. - Security: retire VirusTotal entirely. ClawHub no longer uploads skill or plugin artifacts to VirusTotal, polls or backfills its results, re-queues ClawScan from VirusTotal updates, delays ClawScan for it, or shows VirusTotal data in the UI, CLI, public API, scan reports, or audit exports. The `clawhub-admin skills repair-vt-pending` command and its API route are removed. - Publishing: remove the in-publish static scan, which ran out of memory on large plugin packages and duplicated the ClawScan pre-publication gate. Static results are no longer computed, sent to ClawScan, or displayed; Skill Cards now wait only for ClawScan. - Publishing: return `503` with `Retry-After` instead of `400`/`401` when Convex reports a transient platform failure (overload, internal/transient error, write admission or conflict) on publish, upload, token-mint, recovery and API-token auth paths; genuine validation errors keep their `4xx` and message. - API: send rate-limit headers only on a real `429`, never on admitted requests or while the rate limiter is switched off. - CLI: retry `503` and real `429` responses with bounded, jittered backoff that honors `Retry-After`, and show quota/reset hints only for a real `429`. - Publishing: pin the server Plugin Inspector to 0.4.3 so large plugin publishes (such as `@openclaw/matrix` and `@openclaw/whatsapp`) stay under the 512 MiB Node action limit; 0.4.4+ type-checks the whole OpenClaw declaration surface while preparing the publish target. Until a bounded Inspector release, retirement notices may name replacements the selected OpenClaw release does not export yet. - CLI: reuse canonical schema implementations during builds while retaining standalone npm artifacts and embedding their debug sources. - Catalog: keep skill and plugin browsing available when optional heading counts fail. - Search: propagate cancelled initial requests without logging expected navigation changes as search failures. - Publishing: bound stored-file metadata verification to 16 concurrent reads and drain started work before cleanup, preserving server-computed hashes and archive bytes. - Tooling: preserve the component example correction and canonical AGENTS.md when refreshing Convex AI guidance. - Docs: clarify that API retirement notices require replacement APIs available in the selected OpenClaw release and appear in the manager dashboard. - Tests: refresh development dependencies and anchor frozen-clock fixtures to Convex transaction timestamps and stored expiration boundaries. - Dependencies: patch Undici to 7.30.1 in the CLI, admin CLI, and development tools to address upstream transport advisories. - Dependencies: refresh production packages, including Convex 1.49 and Workpool 0.4.15. Convex now requires Node.js 22 or newer; do not downgrade Workpool after its new queue pointers are stored, and complete its upstream backfill before a future 0.5 upgrade. - CI: escape Unicode line separators in security dataset JSONL so line readers preserve complete records during snapshot validation. - CI: reuse Playwright browser downloads across unrelated dependency updates by keying caches to the installed Playwright version and runner architecture. - CI: use a single-commit checkout for static checks instead of fetching full history. - CI: cache the pinned OpenClaw contract package store while retaining frozen installs and full contract proof on every run. - Tooling: use the existing pinned Bun formatter for format commands while preserving Oxfmt configuration and exclusions. - Publishing: prepare staged ClawPacks in the Node runtime so large archives can reach package validation without exhausting the HTTP action memory limit. - Scanning: stop classifying Manifest V3 browser host permissions as installation sources while retaining checks for install URLs elsewhere in the manifest. - CI: speed up the Linux root typecheck with pinned tsrs while retaining native TypeScript for local checks and package builds. - CI: run native package typechecks in the packages job only, retaining full package checks in local `ci:types-build`. - CI: run command-script tests in Node instead of starting jsdom for each suite. - skills.sh: sync once a day at 03:00 Pacific and mirror the top 4,000 rows of the all-time and trending views, so the sync completes again after skills.sh expanded its default feed to ~93k rows; Trending keeps the last skills.sh run for up to 50 hours. - Workers: include bounded, redacted skill evaluation failure reasons in CI logs so operators can diagnose failed runs. - Tooling: accept Bun's environment-file loading diagnostic in local dependency audits while preserving tool-error and malware failures. - Plugins: show informational notices for OpenClaw APIs with scheduled retirement dates, with replacement details and a publisher dashboard nudge. - Dependencies: update Plugin Inspector to 0.4.0 in the app and CLI to retain structured API retirement guidance; the CLI now requires Node.js 22.13+ on the 22.x line or Node.js 24+. - CLI/Scans: load Plugin Inspector only for validation, select Node.js 24 for hosted Convex actions, and run bulk scans under Node.js; ordinary Bun CLI commands remain available, while local plugin validation explains its Node.js requirement. - Dependencies: patch vulnerable DOMPurify, Next.js preview tooling, shell-quote, and source-map-js versions. - Dependencies: refresh supported React, TanStack, Radix, email, CLI utility, lint, format, and test packages while retaining the current Node and compiler compatibility contracts. - Tests: update Vitest and its V8 coverage provider together to 5.0.3; retain registered auth callbacks across per-test mock cleanup. - Tests: update jsdom to 30.1.2 and allow its required Undici 8 transport while keeping the CLI on Undici 7. - Runtime: use Bun 1.3.14 across CI and deployment tooling to preserve labelled conditional blocks when compiling React server rendering. - Tests: revalidate cached npm metadata before installing updated Convex external dependencies, retaining cached package tarballs and bounded fetches. - Dependencies: refresh production packages and synchronize the Sharp pin; let each package resolve its supported Undici transport and use the unpatched upstream Workpool release. Retain the old Workpool typecheck patch only for the previous-version test fixture. - Use one shared autoreview installation from `openclaw/agent-skills`; repository entrypoints now receive upstream fixes without copied helpers or test suites. - CI: batch main CodeQL scans every six hours while preserving PR and manual scans; include local composite actions and attribute-only PR changes. - Tooling: generate schema build output during workspace install and Worktrunk setup instead of tracking compiled files; installs that skip scripts must build the schema package before use. ### Release Proof - npm: https://www.npmjs.com/package/clawhub/v/0.26.0 - tarball: https://registry.npmjs.org/clawhub/-/clawhub-0.26.0.tgz - integrity: sha512-KMfkxT79Eb6dauDtZDUXCazpMz7kBYZC3nB5Bnkj8yvoAAQlGuRy6G1y0aPAsQ5Y9uYP+xjXcGB/HfzSAsuYpg== - npm preflight: https://github.com/openclaw/clawhub/actions/runs/43353954827 - npm publish: https://github.com/openclaw/clawhub/actions/runs/43354207902
-
v0.25.1
GitHub ↗
Original release notes
## 0.25.1 - 2026-11-03 ### Fixes - CLI: update Plugin Inspector to 0.4.5 so API retirement notices require replacement APIs available in the selected OpenClaw release. - Dependencies: patch Undici to 7.30.1 and update ArkType, ignore, and mime to their latest patch releases. ### Release Proof - npm: https://www.npmjs.com/package/clawhub/v/0.25.1 - tarball: https://registry.npmjs.org/clawhub/-/clawhub-0.25.1.tgz - integrity: sha512-OvImDyHSXPF5ypL3KpM18Ck7F2SKBD0z8ZWGzDl11kGE0dHoTJmX8935FuJwOvFCY8oGGIzT204RoWkWVGkAyQ== - npm preflight: https://github.com/openclaw/clawhub/actions/runs/41647745429 - npm publish: https://github.com/openclaw/clawhub/actions/runs/41648297345
-
v0.25.0
GitHub ↗
Original release notes
## 0.25.0 - 2026-11-01 ### Compatibility - Experimental Claw packages are now Templates. Use `clawhub package explore --family template` and `clawhub package publish <artifact.tgz> --family template`; `--family claw` is rejected. Public scoped routes use `/<owner>/templates/<slug>` instead of `/<owner>/claws/<slug>`. - New packages use `openclaw.template` in `package.json`. `CLAW.md`, existing package/version identities and published artifact bytes remain unchanged. ### Fixes - CLI: show the publishing step, file position, HTTP status and safe request ID when an upload fails, while preserving retry timing and existing error messages. ### Release Proof - npm: https://www.npmjs.com/package/clawhub/v/0.25.0 - tarball: https://registry.npmjs.org/clawhub/-/clawhub-0.25.0.tgz - integrity: sha512-G+ofWmCHK0w/kl2MWaKurYlnucw1cUbWnH7ecRUo0uzKmmSmQI9YyyaphZV+jqt8m2pCDT4j9edHiuv3LxSa0A== - npm preflight: https://github.com/openclaw/clawhub/actions/runs/41279997287 - npm publish: https://github.com/openclaw/clawhub/actions/runs/41280523399
-
v0.24.1
GitHub ↗
Original release notes
## 0.24.1 - 2026-10-28 ### Fixes - CLI/API: let authorized skill owners inspect the publication state of an exact held version, including failed checks and active retries, without exposing private uploads publicly. Avoid reporting a clean older release as the held version's result, and fail file reads until that version is available. ### Compatibility - The CLI includes Plugin Inspector 0.4.3 and requires Node.js 22.13+ on the 22.x line or Node.js 24+. ### Release Proof - npm: https://www.npmjs.com/package/clawhub/v/0.24.1 - tarball: https://registry.npmjs.org/clawhub/-/clawhub-0.24.1.tgz - integrity: sha512-je0nAOJvXBhA1WaIwLFL+9MKDNQBhu+23N074pvB3s8XCKAOV/QfjgWCr8Co2AGCGO8yE0KmllfUOqPs2CDTlQ== - npm preflight: https://github.com/openclaw/clawhub/actions/runs/40642033913 - npm publish: https://github.com/openclaw/clawhub/actions/runs/40642249975 - [Installed npm CLI and production verification](https://github.com/openclaw/clawhub/pull/4110#issuecomment-6462153133) The signed npm publish was accepted while npm processed the version. The workflow’s short post-publish metadata wait expired; the public registry artifact and installed CLI were verified afterward.
Only the five most recent versions are shown. View full version history at the source ↗
Current listing version
0.0.1
Safety and assessment details
Quality assessment
Out of 100 · Assessment report from SkillPi LAB.
Highlights
- 针对 Convex 应用性能审计,解决读取放大、OCC 冲突、订阅成本、函数限制等具体性能问题
- 提供了清晰的适用场景(功能运行缓慢、洞察发现、OCC 冲突、读取放大)和不适用场景
Areas to improve
-
description内容截断 Reported severity: Minor
frontmatter 中的 description 字段在 'and' 处被换行截断,导致内容不完整
Recommendation: 将 frontmatter 中的 description 合并为单行,或确保换行不影响语义完整性
Highlights
- 触发词精准完整,覆盖多种变体,边界清晰
- 明确描述了适用场景和不适用场景,减少误触风险
Highlights
- Phase/步骤清晰,包含 When to Use/Not to Use、Guardrails、Workflow、Checklist 等完整结构
- 提供了端到端示例和具体的检查清单,便于用户执行
Highlights
- 工具来源明确(Convex CLI、insights、convex-doctor),参数正确
- 覆盖主要异常(如 CLI 版本过旧的处理),不可逆操作有确认机制(Verify before finishing)
The arithmetic mean of the first four original scores, rounded to a whole number.
Static text checks
100 / 100 · skillpi-20261123-no-r3-v1
No current rules matched the text.
This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.
Permissions and checks before use
Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.
-
Install or fetch external dependencies
Use official sources and pin versions. Check install scripts in an isolated environment. This document check does not cover code downloaded later.
Mentioned in main document · lines 16, 48, 51
Domains or addresses referenced in the document
These addresses may be documentation links or examples, not an approved network allowlist. Verify actual destinations and outgoing data before use.
- docs.convex.dev
Security rating and access scope
safe · Static evidence review; not a runtime safety guarantee.
Not specified in the source documentation.
Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.
User discussion
No verified reviews yet.