convex-performance-audit

Diagnoses and fixes Convex performance issues across reads, writes, subscriptions, and function limits.

Updated Apr 30, 2026
One-click install
npx skills add https://github.com/AdityaBorkar/igbot-fork --skill convex-performance-audit-adityaborkar
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: convex-performance-audit
Source: https://github.com/AdityaBorkar/igbot-fork/tree/main/.agents/skills/convex-performance-audit
Command: npx skills add https://github.com/AdityaBorkar/igbot-fork --skill convex-performance-audit-adityaborkar

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Convex applications can become slow or expensive due to read amplification, OCC write conflicts, excessive reactive subscriptions, or functions hitting execution and transaction limits. This Skill provides a structured audit workflow that starts from real signals (Convex insights, logs, or code review) and routes each symptom to targeted fixes. ## Core Features & Use Cases - Signal-Based Diagnosis: Gathers evidence from npx convex insights --details, deployment health data, or code audits, then routes the symptom to the right problem class. - Four Problem-Class Playbooks: Reference guides cover hot-path read amplification, OCC conflicts and write contention, subscription cost and invalidation, and function budget limits. - Sibling Function Consistency: Ensures fixes are applied across all functions touching the same tables, not just the one flagged by an insight. - Use Case: Your dashboard shows high bytes read on a list query. The Skill traces the full read/write set, replaces scan-and-filter with an indexed query or digest table, checks sibling queries for the same pattern, and verifies no regressions. ## Quick Start Ask the assistant to audit your Convex app for performance issues, starting with the strongest available signal such as insights output or a slow page.

Frequently Asked Questions about convex-performance-audit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I fix slow Convex queries with high bytes read?▼

Run npx convex insights --details to identify the hot function, then replace scan-and-filter patterns with withIndex or withSearchIndex queries. For hot list pages, consider digest tables that read smaller document shapes instead of full source documents.

How to resolve OCC conflict errors in Convex mutations?▼

OCC conflicts come from write contention on shared documents or broad read sets. Narrow reads with indexes, split hot documents like counters into shards, skip no-op writes, and move non-critical bookkeeping to scheduled functions.

Does Convex .filter() push predicates to the storage layer?▼

No. The Convex .filter() method performs the same as JavaScript filtering after a scan; you still pay for every document read. Only .withIndex() and .withSearchIndex() actually reduce the documents scanned at the storage layer.

When should I use point-in-time reads instead of useQuery subscriptions?▼

Use point-in-time reads when the flow is high-read, the data changes less often than users need to see, and explicit refresh is acceptable. Keep reactive subscriptions for collaborative editing, live dashboards, and presence-heavy views.

Why does Date.now() inside a Convex query cause performance problems?▼

Date.now() defeats Convex's query cache because results change constantly, forcing frequent re-evaluation even when underlying data is unchanged. Use a boolean field updated by a scheduled function, or pass a coarsely rounded timestamp as an argument.

When should I not apply digest tables or document splitting in Convex?▼

Avoid structural changes when scale is small, traffic is modest, or signals are weak. A simple scan on a small table is often acceptable, and migration-heavy rollouts are only justified by measured signals or clearly unbounded hot paths.