Skip to main content

The world's first named AI prompt quality score. Score and optimize prompts before LLM inference.

Project description

PQS SDK — Prompt Quality Score for Python

The world's first named AI prompt quality score.
Score and optimize prompts before LLM inference. Built for developers, AI agents, and CrewAI workflows.

"Cheaper than one bad prompt."


Install

pip install pqs-sdk

# With CrewAI integration
pip install pqs-sdk[crewai]

Get a Free API Key

pqs.onchainintel.net — free scoring, no credit card required.


Quick Start

Score a prompt

from pqs_sdk import PQSClient

client = PQSClient(api_key="your-pqs-api-key")

result = client.score("help me write a blog post", vertical="content")
print(result)
# → PQS Score: 8/40 | Grade: F | Fail | Prompt lacks context, audience, and goal

Optimize a weak prompt

optimized = client.optimize("help me write a blog post", vertical="content")
print(optimized)
# → Optimized: F (8/40) → B (31/40) [+23 pts]

print(optimized.optimized_prompt)
# → Write a 1,000-word blog post for senior software engineers about...

CrewAI Integration

Add PQS as a pre-flight quality gate to any CrewAI agent in 3 lines:

from crewai import Agent
from pqs_sdk import PQSScoreTool, PQSOptimizeTool

# Initialize tools
pqs_score = PQSScoreTool(api_key="your-pqs-api-key")
pqs_optimize = PQSOptimizeTool(api_key="your-pqs-api-key")

# Add to any agent
agent = Agent(
    role="Research Analyst",
    goal="Conduct quality research with well-crafted prompts",
    backstory="You always score prompts before sending them to an LLM.",
    tools=[pqs_score, pqs_optimize]
)

That's it. Your agent now scores every prompt before inference — catching weak inputs before they waste tokens or produce bad outputs.


Verticals

PQS scores prompts across 7 domain verticals:

Vertical Use Case
software Code generation, debugging, architecture
content Blog posts, copywriting, social media
business Strategy, analysis, emails
education Tutoring, explanations, curriculum
science Research, data analysis, hypothesis
crypto Web3, DeFi, blockchain analysis
general General purpose

Pricing

Endpoint Cost
Score Free
Optimize $0.025 USDC
Compare (Claude vs GPT-4o) $1.25 USDC

Payments via x402 on Base mainnet. Agents pay natively — no human in the loop.


Why PQS?

89% of real prompts score D or F. The AI input quality problem is real — and PQS named it.

Bad inputs produce bad outputs regardless of model quality. PQS is the missing pre-flight layer between human intent and model execution.

PQS is to AI agents what a linter is to code. You wouldn't push code without checking it. Don't send a prompt without scoring it.


Links


MIT License © 2026 Ken Burbary / OnChainIntel

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

prompt_quality_score-1.1.0.tar.gz (6.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

prompt_quality_score-1.1.0-py3-none-any.whl (7.0 kB view details)

Uploaded Python 3

File details

Details for the file prompt_quality_score-1.1.0.tar.gz.

File metadata

  • Download URL: prompt_quality_score-1.1.0.tar.gz
  • Upload date:
  • Size: 6.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for prompt_quality_score-1.1.0.tar.gz
Algorithm Hash digest
SHA256 fd7cc904cbdc30932dfb5d4153d9d94ced7ae5b8485062c152fdbbcec0439719
MD5 43039590d3fdb13b4cdf8ed71f752e2f
BLAKE2b-256 da39f7245b43d150761feab156d6947e896e1b3043d91d838f7820f28e4c3884

See more details on using hashes here.

File details

Details for the file prompt_quality_score-1.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for prompt_quality_score-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 aeaf8513a1ee2e61aa75f3bcbd70abc8ebe53ec93bad8a2f90d6b4bf25bb3788
MD5 1ae890f2079a329c7a788dfaf7124d58
BLAKE2b-256 1b903a17b99d6c7da5dc7507677c8dc5b30d72105e08fabdb490827a42366625

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page