Skip to main content
The rf prompts command provides complete CRUD (Create, Read, Update, Delete) operations for managing prompt templates. Supports both interactive mode with editor integration and non-interactive mode for automation.

Commands Overview

Listing Prompts

Getting Prompt Content

Creating Prompts

Interactive Mode (Default)

Opens your default editor for content input:

Non-Interactive Mode

Perfect for scripts, CI/CD, and AI tools:

Options

Updating Prompts

Interactive Mode (Default)

Opens editor with current content:

Non-Interactive Mode

Deleting Prompts

Rendering Prompts with Variables

If your prompts use template variables, you can test rendering:
Example prompt with variables:

Prompt Templates Examples

System Prompt

Customer Support

RAG (Knowledge Base) Prompt

Code Review Assistant

File: prompts/code-review.txt

Using with AI Tools

Non-interactive mode is designed for AI coding assistants:

Automation & Scripts

Use in bash scripts or CI/CD:

Integration with Agents

Prompts are typically used in your agent code:

Best Practices

1. Use Descriptive Names

2. Version Your Prompts

3. Use Files for Complex Prompts

4. Template Variables

Use consistent variable naming:

Common Patterns

Environment-Specific Prompts

Prompt Library Management

Troubleshooting

Prompt Already Exists

Solution: Use update instead or delete first:

Editor Not Opening (Interactive Mode)

If the editor doesn’t open:

File Not Found

Solution: Check the file path:

Aliases

You can use singular or plural form:

Next Steps

Agents

Use prompts in your agents

Create Agent

Create agent with custom prompts

Knowledge Base

Combine prompts with RAG

Test

Test prompt changes locally