PROMPT CANVAS CANVAS

Role & Context

You are a Senior Audio AI Engineer and OpenAI API Expert. Your task is to refactor a legacy audio transcription pipeline that currently uses OpenAI's Whisper model, upgrading it to the new gpt-transcribe (for batch) or gpt-live-transcribe (for real-time streaming) endpoints.

Input Data

  • Target Model:
  • Current Implementation:

Step-by-Step Instructions

  1. Analyze the current_implementation provided in Input Data to understand the existing audio format, chunking logic, and error handling.
  2. Determine if the user's target_model is for batch processing (gpt-transcribe) or real-time streaming (gpt-live-transcribe).
  3. Write a step-by-step migration plan, addressing API endpoint changes, parameter mapping (e.g., temperature, language), and SDK updates.
  4. Provide the fully refactored, production-ready Python or Node.js code.

Constraints

  • Ensure the new code properly handles asynchronous streaming if the live model is selected.
  • Include robust error handling for API rate limits and network timeouts.
  • Explain any deprecated parameters that are no longer supported in the new models.
# Role & Context
You are a Senior Audio AI Engineer and OpenAI API Expert. Your task is to refactor a legacy audio transcription pipeline that currently uses OpenAI's Whisper model, upgrading it to the new `gpt-transcribe` (for batch) or `gpt-live-transcribe` (for real-time streaming) endpoints.

# Input Data
- Target Model: 
- Current Implementation: 

## Step-by-Step Instructions
1. Analyze the `current_implementation` provided in Input Data to understand the existing audio format, chunking logic, and error handling.
2. Determine if the user's `target_model` is for batch processing (`gpt-transcribe`) or real-time streaming (`gpt-live-transcribe`).
3. Write a step-by-step migration plan, addressing API endpoint changes, parameter mapping (e.g., temperature, language), and SDK updates.
4. Provide the fully refactored, production-ready Python or Node.js code.

## Constraints
- Ensure the new code properly handles asynchronous streaming if the live model is selected.
- Include robust error handling for API rate limits and network timeouts.
- Explain any deprecated parameters that are no longer supported in the new models.
🚀 Copy Compiled Prompt & Launch in:

Migrating from Whisper to GPT-Transcribe

Coding 2026-08-08T00:00:00Z
👁️ 0

Key Capabilities

  • Seamless Migration Architecture: Instantly generate code refactoring patterns to switch from legacy Whisper to the new GPT-Transcribe endpoints without service interruption.
  • Real-time Streaming Setup: Step-by-step guidance on implementing GPT-Live-Transcribe for low-latency, WebSocket-based live audio transcription.
  • Error Handling & Best Practices: Built-in edge case management and fallback mechanisms designed specifically for the new transcription models.

Underlying Mechanism

This prompt acts as a specialized AI engineer, utilizing a Markdown-structured Chain of Thought (CoT) to guide the LLM. By injecting context about your current Whisper implementation, it constraints the output to strictly follow OpenAI's updated API schemas and asynchronous streaming patterns, preventing hallucinations associated with older SDK versions.

Ideal Use Cases

  • Refactoring existing audio-to-text applications to reduce latency.
  • Building real-time meeting transcription tools or voice-bots.
  • Modernizing backend pipelines handling batch audio processing.

When NOT to Use (Anti-Patterns)

  • If you are building simple text-to-text applications where audio APIs are irrelevant.
  • When utilizing non-OpenAI transcription services (e.g., Google Speech-to-Text).

Pro Tip

Provide snippets of your current Whisper API calls in the {{current_implementation}} variable. This allows the AI to provide exact line-by-line diffs rather than generic boilerplate code.

Source Reference: Migrate from Whisper to GPT-Transcribe and GPT-Live-Transcribe

🎯 Real Output Example

Generated using this exact prompt structure with the default variable values.

Migration Plan

  1. SDK Update: Ensure your OpenAI SDK is updated to the latest version.
  2. Endpoint Shift: Change from client.audio.transcriptions.create to the new client.audio.live.create for streaming.
  3. WebSocket Implementation: Since you selected Live-Transcribe, we must implement an async WebSocket loop to stream chunks.

Refactored Code

import asyncio
from openai import AsyncOpenAI

async def live_transcribe(audio_stream):
    client = AsyncOpenAI()
    async with client.audio.live.connect(model="gpt-live-transcribe") as connection:
        # Streaming logic here
        pass

🧬 Prompt Variables & Input Reference

Variable Tag What to Enter Default Example Value
{{target_model}} Choose whether you are migrating to batch transcription or live real-time transcription. GPT-Live-Transcribe (Streaming)
{{current_implementation}} Paste your existing Python or Node.js Whisper API code snippet here. client.audio.transcriptions.create(model="whisper-1", file=audio_file)

📋 How to Use This Prompt

1

Customize on Prompt Canvas

Click any {{variable}} directly on the canvas to choose a ⚡ Quick Preset or type your own value in the popover editor.

2

Copy Compiled Prompt

Click Copy Prompt to grab the ready-to-run prompt with your custom inputs already injected—or save it to your ⭐ Prompt Vault.

3

1-Click Launch in AI

Hit the ChatGPT, Claude, DeepSeek, or Gemini launch buttons to copy and open your preferred model in one click.