Token导航 LogoToken导航TokenDH.com
研究检索external-servicegithub未标认证来源可访问许可证需确认审计通过

tool-design工具设计

Agent Skill

用于辅助界面设计、视觉规范、排版、配色、布局和交互体验优化。它适合让 Agent 根据产品场景整理页面结构、生成 UI 方案、检查视觉一致性或改进组件层级。使用时需要结合现有品牌、设计系统和用户任务,不应只堆装饰元素;涉及真实页面改动时,应通过截图或浏览器预览检查文本溢出、对齐和响应式表现。

总安装

921

周安装

38

GitHub Stars

4

下载量

301
CodexClaudeCursorGemini CLI

安装说明

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

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

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

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

命令行安装

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

skills.shnpx skills
npx skills add https://github.com/eyadsibai/ltk --skill tool-design

简介

tool-design 指导 Agent 工具的契约设计与职责划分。

  • 强调单一职责与明确输入输出,减少模糊调用。
  • 帮助定义何时使用何种工具而非罗列多个相似接口。
  • 设计不当会导致系统性失败,需人工介入校验逻辑一致性。
  • 适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

SKILL.md

Tool Design for Agents

Tools define the contract between deterministic systems and non-deterministic agents. Poor tool design creates failure modes that no amount of prompt engineering can fix.

The Consolidation Principle

If a human engineer cannot definitively say which tool should be used, an agent cannot do better.

Instead of: list_users, list_events, create_event Use: schedule_event (finds availability and schedules)

Tool Description Structure

Answer four questions:

  1. What does the tool do?
  2. When should it be used?
  3. What inputs does it accept?
  4. What does it return?

Well-Designed Tool Example

def get_customer(customer_id: str, format: str = "concise"):
    """
    Retrieve customer information by ID.

    Use when:
    - User asks about specific customer details
    - Need customer context for decision-making
    - Verifying customer identity

    Args:
        customer_id: Format "CUST-######" (e.g., "CUST-000001")
        format: "concise" for key fields, "detailed" for complete record

    Returns:
        Customer object with requested fields

    Errors:
        NOT_FOUND: Customer ID not found
        INVALID_FORMAT: ID must match CUST-###### pattern
    """

Poor Tool Design (Anti-pattern)

def search(query):
    """Search the database."""
    pass

Problems: Vague name, missing parameters, no return description, no usage context, no error handling.

Architectural Reduction

Production evidence shows: fewer, primitive tools can outperform sophisticated multi-tool architectures.

File System Agent Pattern: Provide direct file system access instead of custom tools. Agent uses grep, cat, find to explore. Works because file systems are well-understood abstractions.

When reduction works:

  • Data layer well-documented
  • Model has sufficient reasoning
  • Specialized tools were constraining
  • Spending more time maintaining scaffolding than improving

MCP Tool Naming

Always use fully qualified names:

# Correct
"Use the BigQuery:bigquery_schema tool..."

# Incorrect (may fail)
"Use the bigquery_schema tool..."

Response Format Optimization

format: str = "concise"  # "concise" | "detailed"

Let agents control verbosity. Concise for confirmations, detailed when full context needed.

Error Message Design

Design for agent recovery:

{
    "error": "NOT_FOUND",
    "message": "Customer CUST-000001 not found",
    "suggestion": "Verify customer ID format (CUST-######)"
}

Tool Collection Guidelines

  • 10-20 tools for most applications
  • Use namespacing for larger collections
  • Ensure each tool has unambiguous purpose
  • Test with actual agent interactions

Anti-Patterns

  • Vague descriptions: "Search the database"
  • Cryptic parameters: x, val, param1
  • Missing error handling: Generic errors
  • Inconsistent naming: id vs identifier vs customer_id

Best Practices

  1. Write descriptions answering what, when, returns
  2. Use consolidation to reduce ambiguity
  3. Implement response format options
  4. Design error messages for recovery
  5. Establish consistent naming conventions
  6. Test with actual agent interactions
  7. Question if tools enable or constrain reasoning
  8. Build minimal architectures for model improvements

适合场景

01

用户想查找某类 Agent Skill 时

02

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

03

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

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

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

能力 4

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

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

平台分布

Codex

34.56%
按下载量换算104

Claude

28.04%
按下载量换算84

Cursor

18.99%
按下载量换算57

Gemini CLI

8.69%
按下载量换算26

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

external-service

该 Skill 可能调用第三方服务、云服务或外部模型 API,使用前需要确认账号、额度、数据发送范围和服务条款。

安装前确认

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

来源信息

继续浏览同类 Skills