Skip to main content
The praisonai-ts CLI provides the prompt-expand command for enhancing prompts with more detail.

Quick Start

1

Simple Usage

praisonai-ts prompt-expand "write a story"
2

With Configuration

praisonai-ts prompt-expand "Write code" --strategy detail --json

Basic Usage

# Expand a prompt (default strategy: auto)
praisonai-ts prompt-expand "write a story"

# Get JSON output
praisonai-ts prompt-expand "create an app" --json
Example Output:
{
  "success": true,
  "data": {
    "originalPrompt": "write a story",
    "expandedPrompt": "Write a compelling narrative with...",
    "strategy": "detail",
    "additions": ["genre", "length", "characters", "plot"]
  }
}

Expansion Strategies

# Detail strategy - add specific details
praisonai-ts prompt-expand "Write code" --strategy detail

# Context strategy - add background context
praisonai-ts prompt-expand "Explain this" --strategy context

# Examples strategy - add example outputs
praisonai-ts prompt-expand "Show me" --strategy examples

# Constraints strategy - add requirements
praisonai-ts prompt-expand "Build a website" --strategy constraints

# Auto strategy (default) - automatically detect best approach
praisonai-ts prompt-expand "Create function" --strategy auto

Available Strategies

StrategyDescription
detailAdd specific details and requirements
contextAdd background context and information
examplesAdd example outputs or formats
constraintsAdd constraints and requirements
autoAutomatically detect the best strategy

SDK Usage

For programmatic usage, see the Prompt Expander SDK documentation.

Prompt Expander SDK

Programmatic expansion

Agent

Agent configuration