latency-critical-systems
Skill10 starsChanged 4 months agoMITView on GitHub
Use when working on latency-sensitive Laravel paths — realtime dashboards, streaming, queues, caches, or execution gateways — where p95 latency and data freshness matter.
2 other projects use a version of this, 2 of them edited.
Adopted by
Most recently taken up by
- templetongroup/radiantedited, first seen Sep 17, 2026
- SamuelNDCE/claude-super-skill-libraryedited, first seen Aug 1, 2026
Other versions2 projects use a version of this.
Word for word · 0
None found.
Edited · 2
- templetongroup/radiant★ 11325% same
- SamuelNDCE/claude-super-skill-library★ 126% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository62 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- analyze-problemSkill
- api-reviewSkill
- article-writingSkill
- assignment-compliance-checkSkill
- automation-audit-opsSkill
- autonomous-loopsSkill
- benchmark-optimization-loopSkill
- benchmarkSkill
- blueprintSkill
- class-refactoringSkill
- cleanup-local-branchesSkill
- codebase-simplification-auditSkill
- code-review-bugsnagSkill
- code-review-githubSkill
- code-review-jiraSkill
- code-reviewSkill
- composer-updateSkill
- create-issues-from-textSkill
- create-issueSkill
- create-missing-tests-in-prSkill
- create-testSkill
- design-systemSkill
- docker-patternsSkill
- e2e-testingSkill
- frontend-a11ySkill
- frontend-design-directionSkill
- frontend-patternsSkill
- frontend-slidesSkill
- git-workflowSkill
- laravel-authorization-reviewSkill
- laravel-securitySkill
- laravel-telescopeSkill
- merge-github-prSkill
- mysql-patternsSkill
- mysql-problem-solverSkill
- penetration-testerSkill
- postgres-patternsSkill
- prepare-issue-contextSkill
- process-code-reviewSkill
- product-capabilitySkill
- production-auditSkill
- pr-staged-merge-planSkill
- pr-summarySkill
- record-project-memorySkill
- redis-patternsSkill
- refactor-entry-point-to-actionSkill
- refresh-claude-mdSkill
- resolve-issueSkill
- rewrite-tests-pestSkill
- security-bounty-hunterSkill
- security-reviewSkill
- security-threat-analysisSkill
- seoSkill
- skill-creatorSkill
- slack-messagingSkill
- smartest-project-additionSkill
- test-driven-developmentSkill
- tester-cookbookSkill
- test-like-humanSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
12 rules. About 0 are common, 11 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈11
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 21
Never trade correctness for speed (see Guardrails).
- Distinctive: line 31
Do not collapse everything into "fast." Track separately:
- Distinctive: line 49
Write the path from event to visible state, then measure each segment:
- Very specific: line 66
Cache stable reads with freshness metadata: Use Cache::remember() / Cache::flexible() against Redis for reads that tolerate a known …
- Distinctive: line 83
Split hot and cold paths: Keep the request fast: do the minimum synchronously, dispatch the rest to a queue.
- Distinctive: line 89
Stream only when it improves freshness: Use broadcasting / websockets (Reverb / Echo) to push fresh data instead of client polling — but …
- Distinctive: line 96
Never claim a latency win from a label.
- Distinctive: line 116
Do not optimize latency by dropping required validation or authorization.
- Distinctive: line 117
Do not hide stale data behind fast cache hits — surface freshness age.
- Distinctive: line 119
Do not claim millisecond behavior from client labels without measurement.
- Distinctive: line 120
Do not gate risky changes loosely: execution-impacting, destructive-migration, or customer-facing deploys need an explicit approval gate …
- Distinctive: line 122
Keep secrets and private payloads out of logs and benchmark artifacts.
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Latency Critical Systems (Laravel)
Engineering approach for latency-sensitive Laravel paths: realtime dashboards, streaming, ingest workers, queues, caches, and execution gateways where p95 latency and freshness matter. This skill is engineering-focused; it does not authorize live trading or financial advice.
Constraints
- Apply
@rules/sql/optimalize.mdcfor every query on the hot path (N+1, eager loading, index usage, batching) - Apply
@rules/laravel/laravel.mdcfor framework-level structure and caching choices - Apply
@rules/laravel/queue-debouncing.mdcwhen smoothing bursty queue work - Measure, do not guess — every claim about latency must come from a real readback.
- Never trade correctness for speed (see Guardrails).
Use when
- A page, API route, broadcast, or dashboard must hit a latency target (p95/p99).
- Queue lag, cache staleness, or freshness age is a visible problem.
- Streaming / websocket freshness or execution-gateway timing is in scope.
- You are deciding where to cache, batch, replicate, or move compute.
1. Split the metrics
Do not collapse everything into "fast." Track separately:
- p50, p95, p99 latency (one slow tail dominates user perception);
- throughput (requests/jobs per second);
- freshness age (how old the displayed data is);
- queue depth and queue wait time;
- cache hit rate;
- provider/external API response time;
- browser render time;
- correctness under load;
- failure and retry behavior.
Capture them with real tools: response timing headers, Horizon metrics,
Redis INFO/MONITOR, slow-query log, and Laravel Telescope for per-request
timing breakdowns.
2. Map the hot path
Write the path from event to visible state, then measure each segment:
source event -> provider API -> ingest job -> queue (Redis/Horizon) -> cache (Redis)
-> Octane worker / route -> broadcast (websocket) -> Livewire/browser render -> userFor each segment record where time goes. The bottleneck is usually one segment, not the whole chain — instrument before optimizing.
3. Optimization order
Apply in this order; stop when the target is met.
- Remove unnecessary round trips. Collapse repeated queries; resolve N+1
with eager loading (
with(...),withCount(...)) per@rules/sql/optimalize.mdc. N+1 on a hot path is the single most common latency killer. Cache stable reads with freshness metadata. Use
Cache::remember()/Cache::flexible()against Redis for reads that tolerate a known staleness window. Store the computed-at timestamp alongside the value.$stats = Cache::remember('dashboard:stats', now()->addSeconds(30), fn () => Order::query()->selectRaw('count(*) c, sum(total) t')->first() );- Batch small calls and writes. Combine per-row queries into bulk
operations (
whereIn,upsert, single keyed read) rather than looping. For bursty event streams, debounce/coalesce queued work per@rules/laravel/queue-debouncing.mdcso one job processes a window of events. - Move compute closer to the data or user. Push aggregation into SQL
(
@rules/sql/optimalize.mdc) instead of hydrating models in PHP; serve reads from a DB read replica where the connection supports it. - Split hot and cold paths. Keep the request fast: do the minimum synchronously, dispatch the rest to a queue. Run hot routes under Laravel Octane so the framework stays booted between requests.
- Apply backpressure before queues grow unbounded. Cap concurrency with
Horizon
maxProcesses/ rate limiting; shed or defer load when queue depth crosses a threshold rather than letting lag compound. - Stream only when it improves freshness. Use broadcasting / websockets (Reverb / Echo) to push fresh data instead of client polling — but only where freshness genuinely improves the experience.
- Add canaries for stale cache, degraded providers, and growing queue depth.
4. Verification — real readbacks
Never claim a latency win from a label; read it back from the running system:
- HTTP timing & headers — measure the route; add a
Server-Timingheader or read response time from logs / Telescope. - Cache state — confirm hit rate via Redis (
INFO stats) and verify the freshness timestamp stored with cached values. - Queue state — check Horizon for wait time, depth, and failed jobs; confirm the hot path is not blocked behind a slow queue.
- Query plans — run
EXPLAINon the hot query (see@rules/sql/optimalize.mdc) to confirm index usage after a rewrite. - Freshness — read the provider/source timestamp and the displayed value; confirm the gap is within the agreed staleness window.
- Browser — verify actual UI freshness (Livewire poll/broadcast updates), not just server numbers.
For execution-adjacent paths, also verify source-data age, provider status, and kill-switch / degraded-mode behavior before calling the path ready.
Guardrails
- Do not optimize latency by dropping required validation or authorization.
- Do not hide stale data behind fast cache hits — surface freshness age; never let a fast cache hit masquerade as live data.
- Do not claim millisecond behavior from client labels without measurement.
- Do not gate risky changes loosely: execution-impacting, destructive-migration, or customer-facing deploys need an explicit approval gate and a rollback path.
- Keep secrets and private payloads out of logs and benchmark artifacts.
Done when
- Each tracked metric (p50/p95/p99, throughput, freshness, queue depth, cache hit rate) has a real, measured value — before and after.
- The hot path is mapped and the actual bottleneck segment is identified.
- Optimizations were applied in order and each win is confirmed by a readback (Telescope/Horizon/Redis/EXPLAIN/browser), not assumption.
- Validation, authorization, and freshness honesty are intact; risky deploys are gated.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

