Skip to main content
Use Cases
  • Updating copy or instructions without a code deploy or redeployment.
  • Sharing a single prompt definition across multiple services or environments.
  • Letting non-engineers iterate on prompts through the UI without touching code.
  • Testing prompt variations safely in staging before promoting to production.

Quick Start

Reference pre-created Prompts instead of inline messages.
Prerequisites: Prompts must be created in AI Studio before use.

Configuration

Important: Cannot use messages (Chat Completions format) and orq.prompt config in the same request. input (Responses API) can be combined with orq.prompt.

Workflow

  1. Create a Prompt in the AI Studio.
  2. Copy prompt ID from the Studio.
  3. Reference in code using prompt config.
  4. Deploy safely knowing prompts are version-controlled.

Version Control Benefits

Production safety:
  • Changes to prompts don’t immediately break production.
  • Test prompt changes before releasing.
  • Rollback capability if issues arise. Development workflow:

Code examples

Error Handling

Best Practices

Prompt management:
  • Use descriptive names for prompts in the Studio.
  • Document prompt purpose and usage.
  • Test prompt changes in staging first.
  • Maintain prompt versioning strategy. Environment strategy:
Fallback strategy:

Troubleshooting

“Prompt not found” errors
  • Verify prompt ID is correct.
  • Check prompt exists in your Orq.ai account.
  • Ensure prompt is published/active.
  • Confirm API Key has access to the prompt. Outdated prompt content
  • Remember “latest” version may have delays.
  • Check prompt was saved in dashboard.
  • Verify you’re using correct environment. Performance issues
  • Prompt resolution adds minimal latency (~10ms).
  • Cache prompt responses like regular requests.
  • Consider local caching for frequently used prompts.

Monitoring

Track prompt usage:
Useful metrics:
  • Which prompts are used most frequently?
  • What’s the error rate per prompt?
  • How often do we fall back to inline messages?
  • What’s the performance impact of prompt resolution?

Advanced Usage

Dynamic prompt selection:
A/B testing with prompts:
Prompt template variables (when supported):

Limitations

  • Pre-creation required: Prompts must exist in Orq.ai before use.
  • Version limitations: Only “latest” version currently supported.
  • Exclusive usage: Cannot mix prompt config with inline messages.
  • Network dependency: Requires connection to Orq.ai for prompt resolution.
  • Account scoped: Prompts cannot be shared across different Orq.ai accounts.

Migration from Inline Messages

Before (inline messages):
After (using prompts):

Team Collaboration

Roles and responsibilities:
  • Developers: Implement prompt references in code.
  • Product managers: Create and refine prompts in dashboard.
  • QA: Test prompt changes before production.
  • DevOps: Manage prompt deployments and rollbacks. Communication workflow:
  1. Product team updates prompt in dashboard
  2. Notifies dev team of changes
  3. Dev team tests with “latest” version
  4. Deploy to production when ready
  5. Monitor performance and rollback if needed