Skip to content

PromptLintLint your LLM prompts

Catch cost waste, security risks, PII leaks, and quality issues before they reach production. 20 intelligent rules, 5 auto-fixes, zero API calls.

PromptLint logo

Quick Start โ€‹

Install via pip or npm, then lint your first prompt:

bash
pip install promptlint-cli
promptlint --file prompt.txt
bash
npm install -g promptlint-cli
promptlint --file prompt.txt
bash
- uses: AryaanSheth/promptlint@v1
  with:
    path: prompts/
    fail-level: warn

Example Output โ€‹

  PromptLint v1.3.0

  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
  โ”‚  File: prompts/system_prompt.txt  (97 tokens ยท ~$0.0005)   โ”‚
  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

  [ CRITICAL ] prompt-injection (line 3)
    Injection pattern detected: 'ignore previous instructions'

  [ CRITICAL ] pii-in-prompt (line 7)
    Email address detected: us**@example.com

  [ WARN ] structure-sections (line -)
    No explicit sections detected (Task / Context / Output)

  [ WARN ] politeness-bloat (line 1)
    Consider removing 'Please' โ€” models don't need it

  [ INFO ] specificity-examples (line -)
    No examples provided โ€” add 1-2 to improve consistency

  โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
  Score: 42/100  Grade: F   5 findings  (2 critical ยท 2 warn ยท 1 info)
  Run with --fix to auto-resolve 3 of these issues

Install via Multiple Channels โ€‹

ChannelCommandWhen to use
pippip install promptlint-cliPython projects & scripts
npmnpm install -g promptlint-cliNode.js projects & pipelines
GitHub ActionAryaanSheth/promptlint@v1Any GitHub-hosted CI
VS CodeSearch "PromptLint" in ExtensionsReal-time editor feedback

20 Rules, 5 Auto-Fixes โ€‹

CategoryRulesAuto-fixable
๐Ÿ’ฐ Cost & Tokenscost, cost-limitโ€”
๐Ÿ”’ Securityprompt-injection, jailbreak-pattern, secret-in-prompt, pii-in-prompt, context-injection-boundaryโœ… 1
๐Ÿ—๏ธ Structurestructure-sections, role-clarity, output-format-missing, hallucination-riskโœ… 1
โœจ Clarityclarity-vague-termsโ€”
๐ŸŽฏ Specificityspecificity-examples, specificity-constraintsโ€”
๐Ÿ“ Verbositypoliteness-bloat, verbosity-redundancy, verbosity-sentence-lengthโœ… 2
๐Ÿ’ช Actionabilityactionability-weak-verbsโ€”
๐Ÿ”„ Consistencyconsistency-terminologyโ€”
โœ… Completenesscompleteness-edge-casesโ€”

Browse all rules โ†’

Released under the Apache 2.0 License.