
Security News
CVE Volume Surges Past 48,000 in 2025 as WordPress Plugin Ecosystem Drives Growth
CVE disclosures hit a record 48,185 in 2025, driven largely by vulnerabilities in third-party WordPress plugins.
CLI tool to execute AI prompts with flexible output formatting
Execute AI prompts directly from your terminal with support for multiple models and structured output formats using OpenRouter and the Vercel AI SDK.
npm install heyi -g
heyi [prompt] [options]
-m, --model <model> - AI model to use (default: openai/gpt-4o-mini)-f, --format <format> - Output format: string, number, object, array (default: string)-s, --schema <schema> - Zod schema for object/array format (required when format is object or array)--file <path> - Read content from file and include as context (can be used multiple times)-h, --help - Display help information-V, --version - Display version numberAPI_KEY - OpenRouter API key (required, can be set via environment or .env file)MODEL - Default AI model to use (optional, can be overridden with --model flag)# Simple text prompt
heyi "What is the capital of France?"
# Use a different model
heyi "Explain quantum computing" --model google/gemini-2.0-flash-exp
# Get structured output as array of strings
heyi "List 5 programming languages" --format array --schema "z.string()"
# Get structured output as array of objects
heyi "List 3 countries with their capitals" --format array --schema "z.object({name:z.string(),capital:z.string()})"
# Get structured output as single object
heyi "Analyze: revenue 100k, costs 60k" --format object --schema "z.object({revenue:z.number(),costs:z.number()})"
# Complex nested schema
heyi "Analyze top 3 tech companies" --format array --schema "z.object({name:z.string(),founded:z.number(),products:z.array(z.string())})"
# Set default model via environment variable
MODEL=perplexity/sonar heyi "Explain AI"
# Set API key via environment variable
API_KEY=your-key heyi "Hello, AI!"
# Input from file as context
heyi "Summarize this content" --file input.txt
# Input from multiple files as context
heyi "Compare these files" --file file1.txt --file file2.txt
heyi "Analyze all these documents" --file doc1.md --file doc2.md --file doc3.md
# Input from stdin
cat article.md | heyi "Extract all URLs mentioned"
echo "Analyze this text" | heyi
--schema flag)--schema flag)The tool uses Zod schemas to ensure the AI model returns data in the requested format. When using object or array formats, you must provide a Zod schema string via the --schema flag.
--format array --schema "z.string()"--format array --schema "z.url()" (not supported by all models)--format array --schema "z.object({name:z.string(),age:z.number()})"--format object --schema "z.object({total:z.number(),items:z.array(z.string())})"# Install dependencies
npm install
# Run tests
npm test
# Lint and format code
npm run format
# Run the CLI in development
npm start -- "Your prompt here"
# Or run directly
./bin/index.js "Your prompt here"
FAQs
CLI tool to execute AI prompts with flexible output formatting
We found that heyi demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
CVE disclosures hit a record 48,185 in 2025, driven largely by vulnerabilities in third-party WordPress plugins.

Security News
Socket CEO Feross Aboukhadijeh joins Insecure Agents to discuss CVE remediation and why supply chain attacks require a different security approach.

Security News
Tailwind Labs laid off 75% of its engineering team after revenue dropped 80%, as LLMs redirect traffic away from documentation where developers discover paid products.