Token导航 LogoToken导航

Agent Skill · 研究检索

accelint-ts-performance(加速 ts 性能)

accelint-ts-performance 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

accelint-ts-performance 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为操作浏览器;许可证信息还不明确,第三方扫描已通过,按安装量在研究检索类的 73,675 个 Skill 里排第 25,107。

总安装 3,843周安装 157GitHub Stars 10下载 1,231核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:accelint-ts-performance(加速 ts 性能)
来源仓库:https://github.com/gohypergiant/agent-skills
仓库路径:skills/accelint-ts-performance
安装命令:
npx skills add https://github.com/gohypergiant/agent-skills --skill accelint-ts-performance
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/gohypergiant/agent-skills --skill accelint-ts-performance

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

accelint-ts-performance 提供系统化的 TypeScript 性能优化方案,针对运行时效率问题提供专家级反模式识别与修复建议。适用于高频率调用的工具函数、渲染循环、实时系统等对性能敏感的场景,帮助发现隐藏的瓶颈。

必须审计所有代码,不因函数看似简单而跳过检查;仅关注性能特定问题,通用最佳实践请用 accelint-ts-best-practices。

安装命令为 npx skills add https://github.com/gohypergiant/agent-skills --skill accelint-ts-performance,需确认是否触发命令执行或网络请求。强调:切勿假设代码为冷路径,即使格式化或验证类函数也可能在高频调用中影响性能。

来源仓库内路径:skills/accelint-ts-performance

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/gohypergiant/agent-skills --skill accelint-ts-…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要操作浏览器,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

accelint-ts-performance 怎么安装?

在终端执行 npx skills add https://github.com/gohypergiant/agent-skills --skill accelint-ts-performanc…。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

accelint-ts-performance 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

accelint-ts-performance 需要什么权限?

权限级别是操作浏览器。该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

accelint-ts-performance 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

accelint-ts-performance 用的人多吗?

公开数据是累计安装 3,843 次,近一周安装 157 次,下载 1,231 次,GitHub 10 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

accelint-ts-performance 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
accelint-ts-performance

加速 ts 性能 · 本页

3,84310操作浏览器未明确通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

TypeScript Performance Optimization

Systematic performance optimization for JavaScript/TypeScript codebases. Combines audit workflow with expert-level optimization patterns for runtime performance.

NEVER Do When Optimizing Performance

Note: For general best practices (type safety with any/enum, avoiding null, not mutating parameters), use the accelint-ts-best-practices skill instead. This section focuses exclusively on performance-specific anti-patterns.

  • NEVER assume code is cold path - Utility functions, formatters, parsers, and validators appear simple but are frequently called in loops, rendering pipelines, or real-time systems. Always audit ALL code for performance anti-patterns. Do not make assumptions about usage frequency or skip auditing based on perceived simplicity.
  • NEVER apply all optimizations blindly - Performance patterns have trade-offs. Balance optimization gains against code complexity. When conducting audits, identify ALL anti-patterns through systematic analysis and report them with expected gains. Let users decide which optimizations to apply based on their specific context.
  • NEVER ignore algorithmic complexity - Optimizing O(n²) code with micro-optimizations is futile. For n=1000, algorithmic fix (O(n² → O(n)) yields 1000x speedup; micro-optimizations yield 1.1-2x at best. Fix algorithm first: use Maps/Sets for O(1) lookups, eliminate nested iterations, choose appropriate data structures.
  • NEVER sacrifice correctness for speed - Performance bugs are still bugs. Optimizations frequently break edge cases: off-by-one errors in manual loops, wrong behavior for empty arrays, null handling issues. Verify behavior matches before and after. Add comprehensive tests covering edge cases before optimizing—catching bugs in production costs far more than any performance gain.
  • NEVER optimize code you don't own - Shared utilities, library internals, or code actively developed by others creates merge conflicts, duplicates effort, and confuses ownership. Performance changes affect all callers; coordinate with owners or defer optimization until code stabilizes.
  • NEVER ignore memory vs CPU trade-offs - Caching trades memory for speed. Unbounded memoization causes memory leaks in long-running applications. A 2x CPU speedup that increases memory 10x can trigger OOM crashes or frequent GC pauses (worse than original slowness). Profile memory usage alongside CPU; set cache size limits; use WeakMap for lifecycle-bound caches.
  • NEVER assume performance across environments - V8 optimizations differ between Node.js versions (v18 vs v20), browsers (Chrome vs Safari), and architectures (x64 vs ARM). An optimization yielding 3x speedup in Chrome may regress 1.5x in Safari. Profile in ALL target environments before shipping; maintain fallback implementations for environment-specific optimizations.
  • NEVER chain array methods (.filter().map().reduce()) - Each method creates intermediate arrays and iterates separately. For arrays with 10k items, .filter().map() allocates 10k + 5k items (if 50% pass filter) and iterates twice. Use single reduce pass to iterate once with zero intermediate allocations, yielding 2-5x speedup in hot paths.
  • NEVER use Array.includes() for repeated lookups - Array.includes() is O(n) linear search. Checking 1000 items against array of 100 is O(n×m) = 100k operations. Use Set.has() instead: O(1) lookup via hash table, reducing 100k operations to 1000 for ~100x speedup. Build Set once upfront; amortized cost is negligible.
  • NEVER await before checking if you need the result - await suspends execution immediately, even if the value isn't needed. Move await into conditional branches that actually use the result. Example: const data = await fetch(url); if (condition) {use(data);} wastes I/O time when condition is false. Better: if (condition) {const data = await fetch(url); use(data);} skips fetch entirely when unneeded.
  • NEVER recompute constants inside loops - Recomputing invariants wastes CPU in every iteration. For 10k iterations, array.length lookup (even if cached by engine) or Math.max(a, b) runs 10k times unnecessarily. Hoist invariants outside loops: const len = array.length; for (let i = 0; i < len; i++) or curry functions to precompute constant parameters once.
  • NEVER create unbounded loops or queues - Prevents runaway resource consumption from bugs or malicious input. Set explicit limits (for (let i = 0; i < Math.min(items.length, 10000); i++)) or timeouts. Unbounded loops can freeze UI threads; unbounded queues cause OOM crashes. Fail fast with clear limits rather than degrading gracefully into unusability.
  • NEVER place try/catch in hot paths - V8 cannot inline functions containing try-catch blocks and marks entire function as non-optimizable. Single try-catch in hot loop causes 3-5x slowdown by preventing inlining, escape analysis, and other optimizations. Validate inputs before hot paths using type guards; move try-catch outside loops to wrap entire operation; use Result types for expected errors.

Before Optimizing Performance, Ask

Apply these tests to focus optimization efforts effectively:

Impact Assessment

  • Is this code actually slow? When profiling data is available, use it to inform prioritization. When unavailable, audit all code for anti-patterns.
  • What percentage of runtime does this represent? When profiling data is available, flame graphs help identify the highest-impact issues. When unavailable, report all anti-patterns found.
  • Raw performance matters - Audit ALL code for performance anti-patterns regardless of current usage context. Utility functions, formatters, parsers, and data transformations are frequently called in loops, rendering pipelines, or real-time systems even when they appear simple.

Correctness Verification

  • Do I have tests covering this code? Performance bugs are subtle. Comprehensive tests catch regressions from optimizations. Add tests before optimizing.
  • What are the edge cases? Off-by-one errors, empty arrays, null/undefined values become more likely with manual loop optimizations. Test exhaustively.

Complexity vs Benefit

  • Is the algorithmic complexity optimal? O(n) → O(1) is 1000x speedup. Micro-optimizations are 1.1-2x at best. Fix algorithm first.
  • Will this optimization persist? If the code changes frequently, optimization may be discarded soon. Optimize stable code first.
  • What's the readability cost? Manual loops are faster but harder to maintain than .map(). Balance performance with team velocity.

How to Use

This skill uses progressive disclosure to minimize context usage:

1. Start with the Workflow (SKILL.md)

Follow the 4-phase audit workflow below for systematic performance analysis.

2. Reference Performance Rules Overview (AGENTS.md)

Load AGENTS.md to scan compressed rule summaries organized by category.

3. Load Specific Performance Patterns as Needed

When you identify specific performance issues, load corresponding reference files for detailed ❌/✅ examples.

4. Use the Report Template (For Explicit Audit Requests)

When users explicitly request a performance audit, load the template for consistent reporting:

Performance Optimization Workflow

Two modes of operation:

  1. Audit Mode - Skill invoked directly (/accelint-ts-performance <path>) or user explicitly requests performance audit

- Generate a structured audit report using the template (Phases 1-2 only) - Report findings for user review before implementation - User decides which optimizations to apply

  1. Implementation Mode - Skill triggers automatically during feature work

- Identify and apply optimizations directly (all 4 phases) - No formal report needed - Focus on fixing issues inline

Copy this checklist to track progress:

- [ ] Phase 1: Profile - Identify actual bottlenecks using profiling tools
- [ ] Phase 2: Analyze - Categorize issues by impact and optimization category
- [ ] Phase 3: Optimize - Apply performance patterns from references/
- [ ] Phase 4: Verify - Measure improvements and validate correctness

Phase 1: Profile to Identify Bottlenecks

CRITICAL: Audit ALL code for performance anti-patterns. Do not skip code based on assumptions about usage frequency. Utility functions, formatters, parsers, validators, and data transformations are frequently called in loops, rendering pipelines, or real-time systems even if their implementation appears simple.

When profiling tools are available, use them to establish baseline measurements:

  • Browser: Chrome DevTools Performance tab
  • Node.js: node --prof script.js && node --prof-process isolate-*.log

Whether profiling data is available or not: Perform systematic static code analysis to identify ALL performance anti-patterns:

  • O(n²) complexity (nested loops, repeated searches)
  • Excessive allocations (template literals, object spreads, array methods)
  • Template literal allocation when String() would suffice
  • Array method chaining (.filter().map())
  • Blocking async operations
  • Try/catch in loops

Output: Complete list of ALL identified anti-patterns with their locations and expected performance impact. Do not filter based on "severity" or "priority" - report everything found.

When generating audit reports (when skill is invoked directly via /accelint-ts-performance <path> or user explicitly requests performance audit), use the structured template:

  1. Load assets/output-report-template.md for the report structure
  2. Follow the template's guidance for consistent formatting and issue grouping

Phase 2: Analyze and Categorize Issues

For EVERY issue identified in Phase 1, categorize by optimization type:

Categorize ALL issues by optimization type:

Issue TypeCategoryExpected Gain
Nested loops, O(n²) complexityAlgorithmic optimization10-1000x
Repeated expensive computationsCaching & memoization2-100x
Allocation-heavy codeAllocation reduction1.5-5x
Sequential access violationsMemory locality1.5-3x
Excessive I/O operationsI/O optimization5-50x
Blocking async operationsI/O optimization2-10x
Property access in loopsCaching & memoization1.2-2x

Quick reference for mapping issues:

Load references/quick-reference.md for detailed issue-to-category mapping and anti-pattern detection.

Output: Categorized list of ALL issues with their optimization categories. Do not filter or prioritize - list everything found in Phase 1.

Phase 3: Optimize Using Performance Patterns

Step 1: Identify your bottleneck category from Phase 2 analysis.

Step 2: Load MANDATORY references for your category. Read each file completely with no range limits.

CategoryMANDATORY FilesOptionalDo NOT Load
Algorithmic (O(n²), nested loops, repeated lookups)reduce-looping.mdreduce-branching.md—memoization, caching, I/O, allocation
Caching (property access in loops, repeated calculations)memoization.mdcache-property-access.mdcache-storage-api.md (for Storage APIs)I/O, allocation
I/O (blocking async, excessive I/O operations)batching.mddefer-await.md—algorithmic, memory
Memory (allocation-heavy, GC pressure)object-operations.mdavoid-allocations.md—I/O, caching
Locality (sequential access violations, cache misses)predictable-execution.md—all others
Safety (unbounded loops, runaway queues)bounded-iteration.md—all others
Micro-opt (hot path fine-tuning, 1.1-2x improvements)currying.mdperformance-misc.md—all others (apply only after algorithmic fixes)

Notes:

  • If bottleneck spans multiple categories, load references for all relevant categories
  • Only apply micro-optimizations if: bottleneck is in hot path, algorithmic optimization already applied, need additional 1.1-2x performance

Step 3: Scan for quick reference during optimization

Load AGENTS.md to see compressed rule summaries organized by category. Use as a quick lookup while implementing patterns from the detailed reference files above.

Apply patterns systematically:

  1. Load the reference file for the identified issue category
  2. Scan the ❌/✅ examples to find matching patterns
  3. Apply the optimization with minimal changes to preserve correctness
  4. Add comments explaining the optimization and referencing the pattern

Example optimization:

// ❌ Before: O(n²) - nested iteration
for (const user of users) {
  const items = allItems.filter(item => item.userId === user.id);
  process(items);
}

// ✅ After: O(n) - single pass with Map lookup
// Performance: reduce-looping.md - build lookup once pattern
const itemsByUser = new Map<string, Item[]>();
for (const item of allItems) {
  if (!itemsByUser.has(item.userId)) {
    itemsByUser.set(item.userId, []);
  }
  itemsByUser.get(item.userId)!.push(item);
}

for (const user of users) {
  const items = itemsByUser.get(user.id) ?? [];
  process(items);
}

Phase 4: Verify Improvements

Measure performance gain:

  1. Re-run profiler with same inputs
  2. Compare before/after runtime percentages
  3. Document speedup factor (e.g., "2.3x faster")

Verify correctness:

  1. Run existing test suite - all tests must pass
  2. Add new tests for edge cases affected by optimization
  3. Manual testing for user-facing functionality

Document optimization:

// Performance optimization applied: 2026-01-28
// Issue: Nested iteration causing O(n²) complexity with 10k items
// Pattern: reduce-looping.md - Map-based lookup
// Speedup: 145x faster (5200ms → 36ms)
// Verified: All tests pass, manual QA complete

Deciding whether to keep the optimization:

  • >10x speedup: Always keep if tests pass
  • 2-10x speedup: Keep if tests pass and code remains maintainable
  • 1.2-2x speedup: Keep for hot paths (>1000 executions/sec) or real-time systems
  • 1.05-1.2x speedup: Keep only if trivial change or critical rendering/animation loop
  • <1.05x speedup: Revert unless it also improves readability

Real-time systems (60fps rendering, live data visualization): Even 1.05x improvements matter in critical hot paths. Use frame timing profiler to verify impact on frame budget (16.67ms for 60fps).

If tests fail: Fix the optimization or revert. Performance bugs are still bugs.

Freedom Calibration

Calibrate guidance specificity to optimization impact:

Optimization TypeFreedom LevelGuidance FormatExample
Algorithmic (10x+ gain)Medium freedomMultiple valid approaches, pick based on constraints"Use Map for O(1) lookup or Set for deduplication"
Caching (2-10x gain)Medium freedomPattern with examples, cache invalidation strategy"Memoize with WeakMap if lifecycle matches source objects"
Micro-optimization (1.1-2x)Low freedomExact pattern from reference, measure first"Cache array.length in loop: for (let i = 0, len = arr.length;...)"

The test: "What's the speedup and maintenance cost?"

  • 10x+ speedup → Worth complexity, medium freedom with patterns
  • 2-10x speedup → Justify with measurements, medium freedom
  • 1.2-2x speedup → Valuable for hot paths and real-time systems, low freedom with exact patterns
  • 1.05-1.2x speedup → Only if trivial change or critical hot path (60fps rendering, etc.)

Important Notes

  • Audit everything philosophy - Audit ALL code for performance anti-patterns. Utility functions, formatters, parsers, and validators are frequently called in loops or real-time systems even when they appear simple. Do not make assumptions about usage frequency.
  • Report all findings - Whether profiling data is available or not, perform systematic static analysis to identify and report ALL anti-patterns with their expected gains. Do not filter based on "severity" or "priority."
  • Reference files are authoritative - The patterns in references/ have been validated. Follow them exactly unless measurements prove otherwise.
  • Hot path definition - Code executed >1000 times per user interaction or >100 times per second in server contexts. For real-time systems (60fps rendering, live visualization), hot paths are functions in the critical rendering loop consuming >1ms per frame.
  • Real-time systems have stricter requirements - 60fps = 16.67ms frame budget. 120fps = 8.33ms. Even 1.05x improvements in hot paths are valuable. Profile with frame timing, not just total execution time.
  • Regression testing - Performance optimizations frequently introduce subtle bugs in edge cases. Add tests before optimizing.
  • Memory profiling matters - Some optimizations (memoization, caching) trade memory for speed. Monitor memory usage in production, especially for long-running real-time applications.

Quick Decision Tree

Use this table to rapidly identify which optimization category applies.

Audit everything: Identify ALL performance anti-patterns in the code regardless of current usage context. Report all findings with expected gains.

If You See...Root CauseOptimization CategoryExpected Gain
Nested for loops over same dataO(n²) complexityAlgorithmic (reduce-looping)10-1000x
.filter() followed by .find() or .map()Multiple passes over dataAlgorithmic (reduce-looping)2-10x
Repeated array.find() or .includes()O(n) linear searchAlgorithmic (reduce-looping, use Set/Map)10-100x
Many if/else chains on same variableBranch-heavy codeAlgorithmic (reduce-branching)1.5-3x
Same function called with same inputs repeatedlyRedundant computationCaching (memoization)2-100x
obj.prop.nested.deep accessed multiple times in loopProperty access overheadCaching (cache-property-access)1.2-2x
localStorage.getItem() or sessionStorage in loopExpensive I/O in loopCaching (cache-storage-api)5-20x
Multiple await fetch() in sequenceSequential I/O blockingI/O (batching, defer-await)2-10x
await before conditional that might not need resultPremature async suspensionI/O (defer-await)1.5-3x
Many object spreads {...obj} or [...arr]Allocation overheadMemory (avoid-allocations)1.5-5x
Creating objects/arrays inside hot loopsGC pressure from allocationsMemory (avoid-allocations)2-5x
Object.assign() or spread when mutation is safeUnnecessary immutability costMemory (object-operations)1.5-3x
Accessing array elements non-sequentiallyCache locality issuesMemory Locality (predictable-execution)1.5-3x
while(true) or unbounded queue growthRunaway resource usageSafety (bounded-iteration)Prevents crashes
Function called with mostly same first N paramsRepeated parameter passingMicro-opt (currying)1.1-1.5x
try/catch inside hot loopV8 deoptimizationMicro-opt (performance-misc)3-5x
String concatenation in loop with +Quadratic string copyingMicro-opt (performance-misc)2-10x

How to use this table:

  1. Identify the pattern from profiler bottleneck
  2. Find matching row in "If You See..." column
  3. Jump to corresponding Optimization Category in Phase 3
  4. Load MANDATORY reference files for that category

平台分布

Codex

36.64%
按下载量换算451

Claude

32.49%
按下载量换算400

Cursor

18.3%
按下载量换算225

Gemini CLI

10.25%
按下载量换算126

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills