Token导航 LogoToken导航TokenDH.com
研究检索只读github未标认证来源可访问许可证需确认审计提醒

cost-estimate成本估算

Agent Skill

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

总安装

1,858

周安装

79

GitHub Stars

公开资料未说明

下载量

651
CodexClaudeCursorGemini CLI

安装说明

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

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

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

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

命令行安装

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

skills.shnpx skills
npx skills add https://github.com/ulpi-io/skills --skill cost-estimate

简介

cost-estimate 基于代码行数与会话时长估算工程人力与基础设施开销。

  • 适用于项目初期预算编制与第三方报价合理性比对。
  • 内置区域费率表与组织乘数因子,支持分支或提交粒度的精准测算。
  • 外部市场研究为可选输入,默认采用内置标准费率。
  • 适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

SKILL.md

Non-negotiable rules:

  1. Use the helper scripts under .agents/skills/cost-estimate/helpers/ instead of redoing LOC, session, or cost math manually.
  2. Keep scope explicit: full repo, branch:<name>, or commit:<hash>.
  3. Separate raw engineering hours from organizational overhead and team multipliers.
  4. Keep the pricing rubric and report schema in references, not inline in the invocation path.
  5. Treat external market-rate research as optional. Use built-in rates unless the user explicitly requests a different market or region.

Cost Estimate

Inputs

  • $request: Optional scope or estimation guidance such as branch:feat/foo, commit:abc1234, region hints, or desired audience

Goal

Produce a credible estimate that:

  • measures the requested code scope with the helper scripts
  • classifies code into the right productivity buckets
  • computes engineering hours and costs without double-counting overhead
  • translates that estimate into realistic calendar and team-cost views
  • reports assumptions, confidence, and Claude ROI clearly

Step 0: Resolve scope and mode

Parse the request into one of:

  • full repository
  • branch:<name>
  • commit:<hash>

If the request is ambiguous, infer full repository by default. If the user supplied region or market hints, carry them into the final rate discussion. Otherwise use the built-in baseline rates.

Success criteria: The estimation target and pricing basis are explicit before running scripts.

Step 1: Measure the real code surface with the helper scripts

Use the helper toolchain in .agents/skills/cost-estimate/helpers/:

  • loc_counter.py
  • git_session_analyzer.py
  • cost_calculator.py
  • report_generator.py

Run loc_counter.py for the resolved scope to capture:

  • total lines
  • file counts
  • language breakdown
  • directory breakdown
  • source vs test vs config vs docs
  • per-file category candidates from all_files

Run git_session_analyzer.py when git history is available so Claude ROI can use actual session estimates rather than LOC fallback.

Rules:

  • prefer the script output over ad hoc find, wc, or inline arithmetic
  • if scope is a branch or commit, measure the diff rather than the full repository
  • if git history is missing or unhelpful, fall back to LOC-based Claude hour estimates later

Success criteria: You have structured JSON for scope size and, when possible, active-session estimates.

Step 2: Classify the code into productivity buckets

Review the loc_counter.py output and map every relevant source line into exactly one category.

Use references/estimation-rates.md for:

  • category keys
  • productivity ranges
  • overhead ranges
  • market-rate baselines
  • role multipliers
  • organizational efficiency constants
  • Claude ROI constants

Classification rules:

  • assign each source line once
  • keep tests, config/build, and documentation separate from product code
  • detect specialized work such as GPU, native interop, audio/video, system extensions, or on-device ML
  • do not inflate complexity without file-level evidence
  • group files when a directory clearly shares one category, but call out exceptional files separately

Success criteria: There is a complete category-to-line-count JSON payload for the calculator.

Step 3: Run the calculator and sanity-check the output

Pipe the category totals into cost_calculator.py.

The calculator should produce:

  • base coding hours
  • overhead hours
  • total estimated hours
  • sanity-check effective lines/hour
  • calendar-time tables
  • engineering-only cost
  • full-team cost
  • Claude ROI fields when Claude hours are available

Rules:

  • do not bake overhead into the category assignment; the calculator already adds overhead
  • if the sanity check falls outside the target range, adjust category assignments or explain why this repo is legitimately outside the norm
  • use built-in market rates by default unless the user explicitly requested a different market basis

Success criteria: The calculator output is internally consistent and the sanity check has been reviewed.

Step 4: Refine Claude ROI and confidence

If session data exists, inspect it and adjust only when the default commit-density heuristic is obviously understating large-scope work. If session data is missing, use the fallback Claude productivity constant from references/estimation-rates.md.

Report:

  • estimated Claude active hours
  • speed multiplier vs the baseline human rate
  • value per Claude hour
  • headline ROI and savings

Also state confidence:

  • high when scope, category mix, and history are clean
  • medium when history or categorization is incomplete
  • low when the request is intentionally approximate or the repo is only partially available

Success criteria: The ROI story is explicit, bounded, and not overstated.

Step 5: Generate the report body

Use report_generator.py to generate the markdown backbone, then refine the narrative where needed.

Load references/report-contract.md for the required report structure and minimum sections.

The final estimate should cover:

  • executive summary
  • codebase metrics
  • development-time estimate
  • calendar-time view
  • engineering-only cost
  • full-team cost
  • Claude ROI
  • assumptions and caveats

Rules:

  • lead with the executive summary and Claude ROI
  • keep the report stakeholder-readable, not tool-dump heavy
  • mention the scope basis explicitly
  • preserve escaped currency formatting when editing prose manually

Success criteria: The estimate is readable, structured, and aligned with the report contract.

Guardrails

  • Do not add disable-model-invocation; this is a read-heavy analysis workflow.
  • Do not add paths:; this is a generic estimation skill.
  • Do not keep pricing tables, role matrices, or full report templates inline in SKILL.md.
  • Do not replace helper-script output with manual math unless the helper chain is unavailable.
  • Do not present a cost number without the scope, assumptions, and confidence level.
  • Do not claim region-specific market validation unless the user explicitly requested it and that research was actually performed.

When To Load References

  • references/estimation-rates.md Use for the productivity buckets, overhead rates, market-rate baselines, team multipliers, efficiency constants, and Claude ROI fallback constants.
  • references/report-contract.md Use for the mandatory section order, reporting contract, and required caveats.

Helper Scripts

  • .agents/skills/cost-estimate/helpers/loc_counter.py

- full repo: no flags - branch diff: --branch <name> (optionally --base <base>) - single commit: --commit <hash> - output: JSON with totals, by_language, by_directory, all_files

  • .agents/skills/cost-estimate/helpers/git_session_analyzer.py

- all commits: no flags - specific branch: --branch <name> - output: JSON with total_commits, total_sessions, estimated_active_hours, sessions[]

  • .agents/skills/cost-estimate/helpers/cost_calculator.py

- input: pipe category JSON on stdin - flags: --rate <hourly>, --claude-hours <N> - valid category keys: simple_crud_ui_boilerplate, standard_views, complex_ui, business_logic, database_persistence, audio_video_processing, gpu_shader, native_interop, system_extensions, on_device_ml, tests, config_build, documentation - output: JSON with base_coding, overhead, total_estimated_hours, sanity_check, calendar_time, engineering_cost, team_costs, claude_roi

  • .agents/skills/cost-estimate/helpers/report_generator.py

- flags: --calc <costs.json>, --sessions <sessions.json>, --project <name>, --scope <desc> - single section: --section <name> - available sections: executive_summary, development_time, calendar_time, engineering_cost, team_cost, grand_total, claude_roi, assumptions - output: ready-to-paste markdown

Use these directly. The judgment work in this skill is classification, calibration, and explanation, not reimplementing the scripts.

Output Contract

Report:

  1. resolved scope and pricing basis
  2. key repo metrics and complexity drivers
  3. engineering hours and sanity-check result
  4. engineering-only and team-cost ranges
  5. Claude ROI and confidence level
  6. assumptions, caveats, and any missing-data limitations

适合场景

01

用户想查找某类 Agent Skill 时

02

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

03

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

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

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

能力 4

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

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

平台分布

Codex

35.14%
按下载量换算229

Claude

29.73%
按下载量换算194

Cursor

20.67%
按下载量换算135

Gemini CLI

10.07%
按下载量换算66

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

可疑

权限和风险

只读

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

安装前确认

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

来源信息

继续浏览同类 Skills