Token导航 LogoToken导航TokenDH.com
研究检索只读github未标认证来源可访问clear审计通过

optimizing-large-skills优化大技能

Agent Skill

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

总安装

441

周安装

18

GitHub Stars

264

下载量

141
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

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

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

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/athola/claude-night-market --skill optimizing-large-skills

简介

帮助管理和优化大型 AI 技能组合的性能与资源占用。

  • 适用于复杂 Agent 系统中技能加载顺序、缓存策略和内存控制。
  • 可辅助拆分大技能为模块化组件以提升响应速度和稳定性。
  • 建议在测试环境中验证其对整体系统负载的影响后再投入生产。
  • optimizing-large-skills 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

Table of Contents

Optimizing Large Skills

Systematic methodology for reducing skill file size while preserving functionality through separation of concerns and strategic code organization.

When To Use

Symptoms that trigger this skill:

  • Skills-eval validation shows "[WARN] Large skill file" warnings
  • SKILL.md files exceed 300 lines
  • Multiple code blocks (10+) with similar functionality
  • Heavy Python implementations inline with markdown
  • Functions >20 lines embedded in documentation

Quick Analysis:

# Analyze any skill file for optimization opportunities
python skills/optimizing-large-skills/tools/optimization-patterns.py \
  skills/path/SKILL.md --verbose --generate-plan

When NOT To Use

  • Skill is under 300 lines and well-organized

Core Pattern: Externalize-Consolidate-Progress

Transformation Pattern

Before: 654-line skill with heavy inline Python implementations After: ~150-line skill with external tools and references

Key Changes:

  • Externalize heavy implementations (>20 lines) to dedicated tools
  • Consolidate similar functions with parameterization
  • Replace code blocks with structured data and tool references
  • Implement progressive loading for non-essential content

Quick Reference

Size Reduction Strategies

StrategyImpactWhen to Use
Externalize Python modules60-70% reductionHeavy implementations (>20 lines)
Consolidate similar functions15-20% reductionRepeated patterns with minor variations
Replace code with structured data10-15% reductionConfiguration-driven logic
Progressive loading patterns5-10% reductionMulti-stage workflows

File Organization

skill-name/
  SKILL.md              # Core documentation (~150-200 lines)
  modules/
    examples.md         # Usage examples and anti-patterns
    patterns.md         # Detailed implementation patterns
  tools/
    analyzer.py         # Heavy implementations with CLI
    config.yaml         # Structured data
  examples/
    basic-usage.py      # Minimal working example

Optimization Workflow

Phase 1: Analysis

  • Identify files >300 lines
  • Count code blocks and functions
  • Measure inline code vs documentation ratio
  • Find repeated patterns and similar functions

Phase 2: Externalization

  • Move heavy implementations (>20 lines) to separate files
  • Add CLI interfaces to externalized tools
  • Create tool directory structure
  • Add usage examples for each tool

Phase 3: Consolidation

  • Merge similar functions with parameterization
  • Replace code blocks with structured data where appropriate
  • Implement progressive loading for non-essential content
  • Update skill documentation to reference external tools

Phase 4: Validation

  • Verify line count <300 (target: 150-200)
  • Test all externalized tools work correctly
  • Confirm progressive loading functions
  • Run skills-eval validation to verify size reduction

Quick Decision Tree

Is skill >300 lines?
├─ No → Continue as-is (well-organized skills don't need optimization)
└─ Yes → Analyze composition
    ├─ Has heavy code blocks (>20 lines)?
    │  └─ Yes → Externalize to tools/ with CLI (60-70% reduction)
    ├─ Has repeated patterns?
    │  └─ Yes → Consolidate with parameterization (15-20% reduction)
    ├─ Has structured config data embedded?
    │  └─ Yes → Extract to config.yaml (10-15% reduction)
    └─ Has non-essential details?
       └─ Yes → Use progressive loading (5-10% reduction)

Key Success Factors

DO:

  • ✅ Always add CLI interfaces to external tools
  • ✅ Keep core concepts inline in SKILL.md
  • ✅ Consolidate related functionality
  • ✅ Include working examples
  • ✅ Test all tools have correct references

DON'T:

  • ❌ Externalize without CLI (hard to use/test)
  • ❌ Create too many small files (increases complexity)
  • ❌ Remove essential documentation (reduces discoverability)
  • ❌ Add complex dependencies (hard to maintain)
  • ❌ Skip usage examples (unclear tool usage)

Next Steps

  1. Run automated analysis: Use optimization-patterns.py to generate optimization plan
  2. Review modules: Check modules/patterns.md for detailed implementation patterns
  3. Learn from examples: Review modules/examples.md for anti-patterns to avoid
  4. Apply systematically: Follow the 4-phase workflow above
  5. Validate results: Run skills-eval to confirm optimization success

Modules

Result

Expected Outcome:

  • 50-70% line count reduction
  • 40-60% token usage reduction
  • No skills-eval warnings
  • Clear separation of concerns
  • Maintainable external tools with CLI interfaces

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Claude Code

29.39%
按下载量换算41

OpenCode

20.51%
按下载量换算29

Cursor

16.64%
按下载量换算23

Codex

13.57%
按下载量换算19

Antigravity

7.65%
按下载量换算11

Gemini CLI

3.36%
按下载量换算5

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

只读

该 Skill 主要提供规则、说明或参考内容,本身偏只读;真正读写文件、联网或执行命令仍取决于宿主 Agent 的任务。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

来源信息

继续浏览同类 Skills