Provider-portable prompts
Write a prompt once and run it against OpenAI, Anthropic, or Groq — switching for cost, latency, or capability without rewriting templates.
When prompts are f-strings glued to a specific SDK, swapping providers means touching every call site. The templates, the parameter plumbing, and the response parsing all assume one vendor, so a migration that should be a config change becomes a refactor.
promptel puts a declarative layer between your application and the SDK. The prompt is authored once in the DSL or YAML; the provider is chosen at call time with { provider }. The day you move for price or a new capability, nothing else in your codebase has to move.
How it flows
- 01
authorWrite the prompt once in a .prompt file with typed params and a technique block.
- 02
executeCall executePrompt(src, params, { provider }) — provider is a flag, not a rewrite.
- 03
switchChange provider to claude or groq for the same file; the SDK-specific details are handled by the abstraction.
- 04
harmonyMulti-channel Harmony responses come back as structured fields, uniform across providers that support them.
What you get
- ✓Provider swaps become a flag change
- ✓Templates and response handling stay vendor-neutral
- ✓No SDK-specific spaghetti scattered across call sites
Try it on a prompt
Run npm install promptel and follow the quickstart.