林特朗(lintlang)

2026-10-22查看 5复制 0

- 针对不明确工具和缺失边界的 Lint 代理说明

Download (.md)

📘如何使用这个技能

  1. 1
    复制技能内容·点击上方「Copy SKILL.md」复制全部内容,或 Download 下载到本地
  2. 2
    打开你的 AI 客户端·支持 Claude Code、Trae、Cursor、ChatGPT、DeepSeek、Kimi 等任意 AI 助手
  3. 3
    粘贴为系统提示/知识文件·Claude Code:放入 .claude/skills/ 目录;普通对话:作为首条消息发送并说「请严格按这份技能文档执行」
  4. 4
    直接提出你的需求·AI 会按技能定义的工作流、格式和约束来处理,无需再解释背景

💡 提示:技能生效后,每次对话只需一句需求,AI 会按 SKILL.md 的流程执行。

SKILL.md2874 chars
---
name: lintlang
description: Use when writing or reviewing AI agent configs, system prompts, or tool definitions (JSON/YAML/Python) and you need to catch ambiguous tool descriptions, missing stop conditions, schema/description mismatches, or embedded prompts before they reach runtime. Deterministic static analysis, no LLM or network calls.
license: Apache-2.0
compatibility: Requires Python 3.10+; installs via pip or runs standalone via `uvx lintlang`. Scans need no network access.
---

# LintLang

LintLang statically analyzes the natural-language instructions that control AI
agents — system prompts, tool descriptions, and configs — catching ambiguous
tools, missing limits, and mixed output formats before they reach an agent
at runtime. It is zero-LLM: deterministic pattern and structural checks only,
no model calls, no telemetry, no network access.

## Use it for

- Linting tool descriptions before agents start choosing between them
  (detects pairs like `get_user_info` / `fetch_user_data` with no
  distinguishing term — check `H1.6`)
- Checking prompts and configs for missing stop conditions, unbounded
  retries, and schema/description mismatches
- Running a zero-LLM CI gate over YAML, JSON, prompt text, and Python source
- Scanning `.py` files for embedded prompts and uncalibrated thresholds
  (detectors `P1`/`P2`)
- Preflighting one present instruction plus explicit typed context before a
  host sends it to a model

## Do not use it for

- Runtime evaluation of a live agent
- Dynamic agent testing or behavioral benchmarking
- Proving an agent is safe in production
- Retrieving preferences from history, deciding truth, or rewriting/sending
  prompts on the agent's behalf

## Quickstart

```bash
python -m pip install lintlang
lintlang scan AGENTS.md
```

Or without installing, via [uv](https://docs.astral.sh/uv/):

```bash
uvx lintlang scan AGENTS.md
```

Scan a fixture with a known finding:

```bash
uvx lintlang scan samples/bad_tool_descriptions.yaml
```

## Output shape

- Repository scan outcomes: `ERROR`, `PASS`, `REVIEW`, or `FAIL`
- Structural findings by pattern `H1` through `H7`, plus Python pipeline
  findings `P1` and `P2`
- JSON output for CI via `--format json`
- Preflight states: `ALLOW`, `NOTICE`, `HOLD`, `UNAVAILABLE`, or `ERROR`
- Preflight evidence uses exact code-point spans and stable `PF001`-`PF005`
  IDs

## Common gotchas

- LintLang judges structure, not runtime model behavior — a config can pass
  every LintLang check and still fail at inference time.
- Configs can be syntactically valid YAML/JSON while still under-specified
  for their intended use; LintLang flags this as `REVIEW`, not `FAIL`.
- Preflight heuristic findings are notice-only; only exact contract/conflict
  rules may hold (`HOLD`).

## More

Full docs, CLI reference, and CI integration:
https://github.com/hermes-labs-ai/lintlang
来源:prompthub

评论0

登录后参与评论

还没有评论,来抢沙发吧