跳到正文
Skillpedia
API 与服务器(后端)280k · #203

latency-critical-systems

它能做什么

这个工具可以帮你检查并优化那些需要快速响应的系统的速度,例如实时仪表盘或交易系统。它会测量各个环节的耗时,并找出可能变慢的地方。

适用场景

  • ✓当实时响应速度至关重要时。
  • ✓当你想了解数据流系统中的瓶颈时。
  • ✓当你想优化数据送达用户的速度时。

技能链接

https://github.com/affaan-m/ECC/blob/main/pi/core/skills/latency-critical-systems/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/affaan-m/ECC/blob/main/pi/core/skills/latency-critical-systems/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“分析一下我的行情数据流的延迟,并找出瓶颈所在。”

每周 5 个新技能,1 分钟读完。

工作原理

这个工具会从多个角度测量速度,例如一个操作完成所需的时间(p50、p95、p99)、数据更新的速度,以及等待队列的大小。它还会梳理数据经过的路径,找出造成延迟的环节。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

Latency Critical Systems

Use this skill when the user cares about realtime behavior, hot paths, streaming freshness, or execution speed. This includes HFT-like infrastructure, but the skill is engineering-focused. It does not authorize live trading or financial advice.

Split The Metrics

Do not collapse everything into "fast." Track:

  • p50, p95, and p99 latency;
  • throughput;
  • freshness age;
  • queue depth;
  • cache hit rate;
  • provider/API response time;
  • browser render time;
  • correctness under load;
  • failure and retry behavior.

Map The Hot Path

Write the path from user/event to final visible state:

source event -> provider API -> ingest worker -> queue -> cache -> edge route
-> client stream -> browser render -> user-visible state

Then measure each segment separately.

Optimization Order

  1. Remove unnecessary round trips.
  2. Cache stable reads with freshness metadata.
  3. Batch small calls and writes.
  4. Move compute closer to the data or the user.
  5. Split hot and cold paths.
  6. Apply backpressure before queues grow unbounded.
  7. Use streaming only when it improves freshness or user experience.
  8. Add canaries for stale data, degraded providers, and bad cache state.

Verification

Use live readbacks when a deployed surface exists:

  • HTTP timing and response headers;
  • provider freshness timestamp;
  • queue or job state;
  • edge/cache state;
  • browser verification for actual UI freshness;
  • logs around retries and degraded mode.

For market-data or execution-adjacent paths, also verify orderbook age, VWAP assumptions, provider status, and kill-switch behavior before calling the path ready.

Guardrails

  • Do not optimize latency by dropping required validation.
  • Do not hide stale data behind fast cache hits.
  • Do not claim millisecond behavior from client labels without measurement.
  • Do not run live orders, destructive migrations, or customer-impacting deploys without an explicit approval gate.
  • Keep secrets and private payloads out of logs and benchmark artifacts.
常见问题

什么是 p50、p95 和 p99 延迟?

它们是速度指标。p50 表示一半的操作完成所需的时间,p95 表示 95% 的操作完成所需的时间,p99 表示 99% 的操作完成所需的时间。它们能帮你同时了解平均速度和最坏情况。

什么是“新鲜度”(freshness age)?

它表示数据的新旧程度。如果数据太旧,可能就没有用处,甚至可能造成损害。

我可以用它来做金融交易吗?

不可以。这个工具专注于提升系统速度的工程优化,不提供投资建议,也不执行交易。

详情

作者的原始描述

Optimize and verify latency-sensitive systems — realtime dashboards, market data feeds, streaming agents, execution gateways, queues, and caches — by tracking p50/p95/p99 latency, freshness age, and queue depth, mapping hot paths, and running live readbacks. Use when p95 latency, throughput, or data freshness matters.

repo: affaan-m/ECC

热度

GitHub 星标
280k
排名
#203
许可证
MIT
更新时间
2026/10/15

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能