Harness-Starter: Skill for Claude Code

.claude/skills/harness-init/SKILL.md

harness-init is a skill for Claude Code from chenklein26-maker/Harness-Starter. It costs 44 tokens per session (1,795 once invoked), scanned A, original, MIT.

A setup procedure for adding the Harness Engineering starter configuration to a new or existing coding project. It detects the project’s language and tools, fills in project guidance, and checks the setup.

In plain words
What is it for?
Use it when installing Harness Starter from GitHub, initializing a new project, or adding Harness to a project already in development. It works with common project files such as package.json, pyproject.toml, go.mod, and Cargo.toml.
Why use it?
It removes the manual work of copying configuration, identifying the technology stack, and replacing template placeholders. It can also help install or configure supporting checks such as hooks and language-server support.

Skill for Claude Code

Written for Claude Code: PreToolUse hook event. Also seen: reads .claude/ paths; mentions CLAUDE.md.

This is chenklein26-maker/Harness-Starter's own configuration. It tells Claude Code how to work on Harness-Starter itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything Harness-Starter configures →

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is cp -r /tmp/harness-starter/scripts/ ./scripts/ 2>/dev/null || true.

Reuse

Borrowing it

Nothing to install: this file belongs to chenklein26-maker/Harness-Starter. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/chenklein26-maker/Harness-Starter/main/.claude/skills/harness-init/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/chenklein26-maker/Harness-Starter

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for harness-init

README.md
[![agentmods](https://agentmods.dev/badge/skills/chenklein26-maker/harness-starter/harness-init.svg)](https://agentmods.dev/skills/chenklein26-maker/harness-starter/harness-init)
Your own site
<a href="https://agentmods.dev/skills/chenklein26-maker/harness-starter/harness-init"><img src="https://agentmods.dev/badge/skills/chenklein26-maker/harness-starter/harness-init.svg" alt="Measured on agentmods" height="20"></a>
Per session 44 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,795 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00044 $0.01795
Opus 5 $0.00022 $0.00898
Sonnet 5 $0.00009 $0.00359
Haiku 4.5 $0.00004 $0.00179

Measured 7d ago against content hash 1934499bb6f9, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

harness-init scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/harness-init/SKILL.md · 175 lines

How it starts

The opening of the file, as written. The whole thing — 175 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Harness Init

适用三种场景:

  • GitHub 安装:用户说"帮我用 Harness Starter 初始化"——还没有模板文件
  • 新项目:模板刚复制过来,CLAUDE.md 含占位符
  • 已有项目:项目已经开发到一半,想加入 Harness

Step 0:检查模板文件是否存在

检查项目根目录下是否有 .claude/hooks/CLAUDE.md

如果不存在(GitHub 安装场景)

用户直接让 AI 安装 Harness Starter,还没有模板文件。需要:

  1. package.jsonrepository 字段获取仓库地址,克隆到临时目录:
    git clone https://github.com/<package.json repository>.git /tmp/harness-starter
    
  2. 复制核心文件到项目:
    cp -r /tmp/harness-starter/.claude/  .claude/
    cp    /tmp/harness-starter/CLAUDE.md ./
    cp    /tmp/harness-starter/.lsp.json ./
    cp    /tmp/harness-starter/.gitignore ./.gitignore 2>/dev/null || true
    cp -r /tmp/harness-starter/scripts/  ./scripts/ 2>/dev/null || true
    mkdir -p .github/workflows 2>/dev/null
    cp -r /tmp/harness-starter/.github/ ./.github/ 2>/dev/null || true
    
  3. 清理临时目录
  4. 继续执行 Step 1

如果已存在

跳过 Step 0,直接执行 Step 1。

Step 1: 检测项目信息

优先从已有文件自动推断,推断不到再问用户:

检查以下文件,提取项目信息:

  • package.json → 项目名、技术栈(React/Vue/Next 等)、测试框架(jest/vitest 等)
  • pyproject.toml → 项目名、Python 依赖
  • go.mod → 模块名、Go 版本
  • Cargo.toml → 项目名、Rust 依赖
  • composer.json → PHP 项目
  • Gemfile → Ruby 项目
  • CMakeLists.txt → C/C++ 项目

对于多语言项目,选择主要技术栈填写。

Step 2: 填写 CLAUDE.md

如果是新项目(含占位符)

用 Step 1 检测到的信息替换 CLAUDE.md 中的 【待填写】 占位符。 如果无法自动推断,询问用户:

  • 用途:这个项目是做什么的?
  • 技术栈:用什么语言/框架?
  • 跑测试:用什么命令?

如果是已有项目(不含占位符)

检查 CLAUDE.md 是否已包含以下核心章节:

  • Karpathy 原则(Think Before Coding / 消除信息差 / 讨论与执行分离 / Simplicity First / Surgical Changes / Goal-Driven Execution)
  • 全局约定
  • 自动审查闭环

如果缺失,补充进去。已有的内容不要覆盖。

Step 3: Skill 路由发现

根据 Step 1 检测到的技术栈,扫描当前可用的 Skill,询问用户最常见的任务类型,生成路由表写入 CLAUDE.md。

3.1 扫描可用 Skill

检查以下位置,汇总所有可用 Skill:

  1. .claude/skills/ — 项目本地 Skill(如 harness-init、harness-mode)
  2. ~/.claude/skills/ — 用户全局 Skill
  3. 当前会话中 [Available Skills] 列表
  4. MCP 工具列表(如果有)

3.2 推断任务场景

根据技术栈列出常见任务类型,例如:

技术栈 常见任务 可路由 Skill
React/Next.js 组件开发、性能优化 vercel-react-best-practices
前端/UI 页面/H5/幻灯片 frontend-slides
Node.js/npm 包管理、构建 项目已有 Skill
Python 测试、格式化 项目已有 Skill
公众号/内容 微信排版、写作 wechat-article-formatter

Read the full file on GitHub · 175 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 175 lines · 44 tokens per session scan A 1934499bb6f9

Subscribe to this mod's changes

harness-init is a skill published in the GitHub repository chenklein26-maker/Harness-Starter (119 stars, last pushed 2mo ago), licensed MIT. It adds 44 tokens to every session and 1,795 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

next-partial-prefetching-adoption

Turn on Partial Prefetching in a Next.js app and work through the insights it surfaces. Use when the user wants to enable or adopt Partial Prefetching, flip the partialPrefetching flag, opt routes in with export const prefetch = 'partial', audit Link prefetch={true} behavior, preserve existing prefetched UI with…

vercel/next.js · 103 tokens

chronicle

Analyze Copilot session history for standup reports, usage tips, session search, and session reindexing. Use when the user asks for a standup, daily summary, usage tips, workflow recommendations, wants to search or find past sessions by keyword/file/PR, wants to reindex their session store, or asks about deleting…

microsoft/vscode · 72 tokens

babysit-pr

Babysit a GitHub pull request after creation by continuously polling review comments, CI checks/workflow runs, and mergeability state until the PR is merged/closed or user help is required. Diagnose failures, retry likely flaky failures up to 3 times, auto-fix/push branch-related issues when appropriate, and keep…

openai/codex · 114 tokens