Browse documentation
Rule reference / LintLang 0.8.0

H5: Implicit Instruction Failure #

A vague qualifier or implicit instruction leaves the expected behavior unclear.

H5LOW–MEDIUMLintLang 0.8.0

Applies to: Recognized prompts and instruction bodies; density checks on chat prompts. Manual repair; no automatic fix for this example.

What triggers it #

Checks selected vague qualifiers, ambiguous conditionals, and figurative verbs. Negative-instruction density and instruction-count checks are restricted to chat prompts; scope and safety-context exemptions apply.

How to repair it #

Replace general advice with observable output requirements that fit the task.

Reproduce the finding #

Use uv and Python 3.10+, plus curl. Run the examples in a scratch directory.

Download the finding example.

{
  "system_prompt": "Be helpful. Use common sense when appropriate."
}
curl -fsS https://lintlang.ai/examples/rules/h5-bad.json -o h5-bad.json
uvx --from lintlang==0.8.0 lintlang scan h5-bad.json --format json

Expected with 0.8.0: the JSON report includes H5, severity LOW. Three LOW H5 findings identify the vague phrases in this example. The improved instruction states the evidence each reported discrepancy must contain.

Improved example #

Download the improved example.

{
  "system_prompt": "List each invoice discrepancy with its line number, expected amount, and stated amount."
}
curl -fsS https://lintlang.ai/examples/rules/h5-improved.json -o h5-improved.json
uvx --from lintlang==0.8.0 lintlang scan h5-improved.json --format json

Expected with 0.8.0: H5 is absent. Other diagnostics may still appear; this repair targets the rule above.

Both commands use advisory mode: a finding does not itself make the command fail. This example is advisory: LOW and INFO findings do not fail either --fail-on threshold. See outputs and exit codes.

Detection details #

Released H5 detection contract and scope

Checks selected vague qualifiers ("be concise", "be helpful", "use common sense"), ambiguous conditionals ("as needed", "when appropriate"), figurative verbs ("lean into", "err on the side of", "keep it simple"). The instruction-count finding is LOW for a literal extracted from Python. In a Markdown document, H2 does not report "loop / repeat / continue until " (a stated termination condition) or text inside a quoted example. For chat prompts only (.txt, .prompt, a config's system prompt, an extracted Python literal) it also checks negative-instruction density and high instruction count without priority ordering; those two judge the shape of a single prompt and do not run on Markdown instruction documents, where they fired on most real files and named no sentence. Negative-instruction exemptions have three layers:

  1. Structural: HTML comments, fenced/inline code, and generated-file markers.
  2. Phrase-level: selected privacy disclaimers, UI labels, descriptive wording, idiomatic phrases, and "to avoid" constructions.
  3. Safety context: nearby security/authentication/policy terms within a 100-character window.

These exemptions and matches are implemented patterns, not unrestricted intent understanding; a useful false-positive report includes a minimal reproduction.

All scan rules · Quickstart · Separate preflight checks.