← Back to list

Stop Treating AI Prompts Like Notes in a Slack Thread — Introducing PromptCache

Viraj Lakshitha Bandara · 2026-06-07 16:16 · 1 claps · 9.8 min read
#ai #engineering #prompt-engineering #developer-tools #llm
Open on Medium ↗
Wiki topics: LLM · Large Language Models AI · AI · General

Stop Treating AI Prompts Like Notes in a Slack Thread — Introducing PromptCache

Every engineering team building AI products eventually hits the same wall: prompts are scattered across Notion docs, Git repos, Slack DMs, and .env files — with no versioning, no collaboration, and no reliable way to push changes to production without a full redeploy. PromptCache is the infrastructure layer your team’s prompts deserve.

Links: Public Gallery · Claude Code MCP Setup · Join the Waitlist

The Problem: Prompt Management Is a Hidden Engineering Debt

When teams first adopt LLMs, prompts start small — a string in a Python file, a constant in a TypeScript module, a doc shared in Notion. Then the product ships. Suddenly those strings drive real user experiences, and every change to them carries production risk.

Here is what that looks like at scale, and why it breaks down:

No single source of truth. The same prompt lives in 3 different services, slightly mutated each time. Which one is canonical? Nobody knows. The on-call engineer finds out during an incident.

Rollbacks require a deployment. A prompt change degrades quality. Rolling it back means reverting a commit, cutting a release, and waiting for CI/CD — even though the change was one paragraph of text.

Collaboration doesn’t exist. Product managers and domain experts who understand the prompt semantics best can’t edit or review them — because they live inside code they can’t touch.

No audit trail. Who changed the system prompt on March 14th? What did it say before? These questions have no answers when prompts live in environment variables or config files.

Teams routinely spend 15–30% of their AI product iteration time on prompt logistics — copying, pasting, hunting down the right version, manually testing variable substitution, and synchronizing changes across services. This is pure engineering overhead that PromptCache eliminates.

What Is PromptCache?

PromptCache is a prompt management platform for teams — a purpose-built CMS for AI prompt templates. Think of it as GitHub for your prompts: version history, branching concepts (draft → published), team collaboration with roles, and a programmatic API for your apps to fetch and render the right prompt at runtime.

Importantly, PromptCache does not run LLM inference. It manages and renders your prompt templates — interpolating typed variables into final text — which you then pass to Claude, GPT, Gemini, or any model of your choice. It’s model-agnostic by design.

The Prompt Lifecycle: Draft, Publish, Invoke

PromptCache introduces a deliberate three-stage lifecycle for every prompt.

1. Draft — the living template

Every prompt starts as a draft. You edit the template text, define typed variables ({{customer_name}}, {{tone}}, {{context}}), set defaults, and mark which are required. Variables are auto-detected — as you type {{variable}}, PromptCache surfaces it in the variables panel immediately. Saving a draft does not create a version.

2. Publish — immutable snapshots

When you’re ready to ship, you publish. Publishing creates an immutable PromptVersion — a timestamped, numbered snapshot of the template and variable definitions. Versions are append-only. You can never edit a published version; you create a new one. This gives you a complete audit trail and makes rollback trivial.

3. Invoke — typed variable rendering at runtime

Your app calls the invoke API (or SDK) with a prompt ID and variable values. PromptCache resolves the active published version, validates required variables, interpolates the template, and returns the final string — ready to send to your LLM. No more string concatenation. No more f-strings. One API call, one rendered prompt.

Feature Deep-Dive

Version Control Built for Prompts

PromptCache’s versioning is purpose-built for prompt workflows — not adapted from Git. Every published version is numbered sequentially, carries the full template snapshot and variable definitions, and is permanently accessible. You can:

  • Browse the full version timeline from the dashboard
  • Diff any two versions (including against the current draft) to see exactly what changed
  • Restore any previous version back to the draft with one click
  • Fork a published version into a brand-new prompt — great for reusing prompt patterns across teams

Engineering benefit: Prompt rollback goes from a deployment event to a single dashboard click. When a prompt change degrades output quality, you restore the previous version in seconds — not minutes.

Preview and Production Environment Slots

Prompts support two pinned environment slots — preview and production — that point to specific published versions. This mirrors the deployment model your team already knows.

Pin a version to preview to test changes end-to-end in your staging environment without affecting production. Call invoke?env=preview in your staging service to pick up this version.

Promote to production when validated. Your production services calling invoke?env=production receive the new version instantly — no deployment required.

Engineering benefit: Ship prompt changes to production without touching your codebase, CI/CD pipeline, or deployment process. Decouples prompt iteration entirely from release cycles.

Typed Variables and Template System

PromptCache’s variable system gives you the ergonomics of a proper templating engine — with type safety and API validation — while staying simple to author.

Variables are written as {{variable_name}} in the template. PromptCache auto-detects them and surfaces them in the variables panel. For each variable you can specify:

  • Type — string, number, boolean, array, object — validated at invoke time
  • Default value — falls back automatically if the caller omits the variable
  • Required flag — API returns 400 if a required variable is missing, no silent failures
  • Description — documents what the variable represents for your team and SDK consumers
  • Live preview — inject variables in the editor to see the rendered output before publishing

The Official TypeScript SDK

The PromptCache SDK (@optiqlabs/promptcache-sdk) is a typed HTTP client that wraps every API operation. It handles authentication, response unwrapping, pagination, and error typing — so your integration code stays minimal.

npm install @optiqlabs/promptcache-sdk
import { PromptCacheClient } from "@optiqlabs/promptcache-sdk";

const client = new PromptCacheClient({
  apiKey: process.env.PROMPTCACHE_API_KEY,
});

// Invoke with typed variables — renders the production version
const result = await client.prompts.invoke("support-reply-template", {
  variables: {
    customer_name: "Alice",
    issue_summary: "Payment failed at checkout",
    tone: "empathetic",
  },
  env: "production",
});

// result.text is the fully rendered prompt, ready for your LLM
const response = await anthropic.messages.create({
  model: "claude-sonnet-4-5",
  messages: [{ role: "user", content: result.text }],
});

The SDK also exposes inject for draft previewing, publish for CI automation, listVersions for changelog tooling, and queueCsvImport for bulk onboarding. See the full SDK documentation for all available methods.

MCP Integration — Manage Prompts Directly from Claude Code

PromptCache ships a remote Model Context Protocol (MCP) server — which means you can connect it to Claude Code and manage prompts without leaving your IDE. This is the fastest way to iterate on prompts while you’re actively developing.

claude mcp add --transport http promptcache https://api.promptcache.app/api/mcp

After running this command, Claude Code opens a browser window for OAuth 2.1 + PKCE authentication. You sign in, pick your workspace, approve the required scopes, and you’re done — no manual token copying. Full setup guide at docs.promptcache.app/mcp-claude-code.

Once connected, 14 MCP tools become available in Claude Code:

Once connected, 14 MCP tools become available directly inside Claude Code. For discovery and navigation, promptcache_list_prompts lets you browse and search your entire prompt library, while promptcache_get_prompt reads the current draft of any specific prompt.

For authoring, promptcache_create_prompt creates a new prompt without leaving the IDE, promptcache_update_prompt updates the draft and surfaces stale variable warnings when the template changes, and promptcache_delete_prompt removes a prompt along with its full version history.

For variable management, promptcache_get_variables lists all variable definitions attached to a prompt, and promptcache_update_variable lets you update a variable's type, default value, or description in place.

For rendering and testing, promptcache_render_prompt substitutes variable values into the template and returns the final string — this is not an LLM call, just template interpolation. promptcache_preview_prompt does the same but without failing on missing required variables, making it useful for partial previews during authoring.

For version control, promptcache_publish_prompt snapshots the current draft into a new published version, promptcache_list_versions shows the full version history of a prompt, and promptcache_get_version reads any specific published snapshot. promptcache_fork_version takes a published version and forks it into a brand-new prompt — useful for reusing prompt patterns across projects or teams.

Finally, promptcache_unpublish_prompt removes a prompt from the public gallery if you no longer want it listed there.

Engineering benefit: The MCP integration closes the loop between prompt authoring and code development. Ask Claude to create, render, or publish prompts as part of your normal coding workflow — no context switching, no browser tabs, no copy-paste.

Team Collaboration, Roles, and Organizations

PromptCache is multi-tenant by design. Every workspace is an Organization with its own prompts, members, API keys, and settings. Team features include:

Role-based access. Two roles: admin (full access including publish, delete, member management) and member (read and draft edits). Prevents accidental production changes from contributors.

Invitations with expiry. Invite teammates by email. Pending invitations have tokens with an expiry date, and admins can cancel them before acceptance.

Audit logs. Append-only log of every action — who created, updated, published, or deleted a prompt, with timestamp, IP, user agent, and API key attribution.

In-app notifications. Team members get notified about version publishes, invitations, and account events without leaving the dashboard.

API Keys, Scopes, Rate Limits, and Webhooks

PromptCache treats API access with the same seriousness as any production API surface:

Scoped API keys. Keys carry explicit scopes: prompts:read, prompts:write, organization:read, organization:write. Principle of least privilege baked in.

Per-key rate limiting. Configurable sliding-window rate limits per API key (default 100 req/15 min). Prevents runaway scripts from hammering the API.

Webhook on version.published. Register org-level webhooks to receive signed payloads whenever a new version is published. Trigger Slack notifications, CI jobs, or downstream cache invalidation automatically.

Signed delivery + retries. Webhooks include an X-PromptCache-Signature header for authenticity verification. Delivery is retried automatically on failure, with full delivery history in the dashboard.

Public Prompt Gallery — Share, Discover, and Fork

When you opt a prompt into public visibility, it appears in the PromptCache public gallery — a searchable, tagged catalog of community prompts. The gallery is designed for discovery and reuse:

  • Browse and search by name, tags, or category — no account required
  • Copy the template text with one click
  • Fork a public prompt into your own workspace to customize it
  • Open directly in ChatGPT, Claude, or Gemini via deep links
  • View counts and fork counts surface what the community finds useful
  • Human-readable share slugs make URLs linkable and memorable

Bulk CSV Import for Large Libraries

Already have hundreds of prompts spread across spreadsheets or docs? PromptCache supports CSV import with background processing via a job queue. Upload your CSV, get a 202 Accepted response immediately, and receive an email notification when the import completes. No timeouts, no manual row-by-row entry.

What PromptCache Eliminates From Your Engineering Workflow

The ROI of PromptCache is best understood through the specific problems it removes — concretely, in the day-to-day of teams building AI products.

Today, rolling back a bad prompt means reverting a commit and waiting for CI/CD to complete — with PromptCache, any version is restored in one click from the dashboard, no deployment involved. Prompt changes buried in Git history become a dedicated version timeline with full diffs and author attribution, so you always know what changed and who changed it.

When the same prompt lives in three different services with subtle mutations in each, there’s no canonical version — PromptCache solves this with a single prompt ID that all services invoke, guaranteeing they always render the same content. Non-engineers who understand the prompt semantics best are completely locked out of code-based workflows; with PromptCache, a PM or domain expert edits the draft in the dashboard and publishes when ready, no developer required.

Manual string formatting and f-strings for variable substitution are replaced by a typed variable system with defaults and required flags, validated server-side at invoke time — no more silent failures from a missing variable. Testing a prompt change no longer means staging the entire application; the preview environment slot lets you switch versions with a single query parameter, not a deploy.

There’s currently no visibility into who changed which prompt and when — PromptCache’s append-only audit log captures every action with actor, timestamp, IP, and API key attribution. Every new service that needs to fetch prompts today has to re-implement the same HTTP fetch logic; with the SDK, it’s one install and one invoke() call. Prompt publishes are invisible to downstream systems until now — webhooks fire on version.published so you can trigger Slack notifications, cache invalidation, or CI pipelines automatically. And finally, managing prompts while coding means constant alt-tabbing to a browser — the MCP integration lets you list, edit, and publish prompts directly inside Claude Code without ever leaving the editor.

Getting Started in 10 Minutes

PromptCache is currently in closed beta. Here’s the path from interest to integration:

Step 1 — Join the waitlist. Head to promptcache.app/join-waitlist to request early access. Once approved, you’ll receive an invitation token to create your account and first organization.

Step 2 — Create your first prompt. From the dashboard, write your template with {{variable}} placeholders, configure variable types and defaults, preview the rendered output, and hit Publish.

Step 3 — Create an API key. Go to API Keys in your organization settings. Create a key with prompts:read scope for your services.

Step 4 — Integrate the SDK.

import { PromptCacheClient } from "@optiqlabs/promptcache-sdk";

const pc = new PromptCacheClient({ apiKey: process.env.PROMPTCACHE_API_KEY });

export async function buildSupportPrompt(customer: string, issue: string) {
  const { text } = await pc.prompts.invoke("support-reply", {
    variables: { customer_name: customer, issue_summary: issue },
    env: "production",
  });
  return text;
}

Step 5 — Connect Claude Code via MCP.

claude mcp add --transport http promptcache https://api.promptcache.app/api/mcp

The full getting-started guide is at docs.promptcache.app.

Prompts Are Infrastructure — Treat Them That Way

The teams that ship the best AI products aren’t the ones with the most models or the most compute — they’re the ones who iterate on prompts fastest and with the most confidence. PromptCache gives you the infrastructure to do exactly that: version history, typed variables, environment slots, team collaboration, a programmatic API, and an IDE-native MCP integration.

The public gallery is live today — no account needed. Browse the community’s prompt library, fork anything useful, and see the platform in action. When you’re ready to bring your own prompts under version control, join the waitlist.


메타데이터
post_id
3edff7aedd18
slug
stop-treating-ai-prompts-like-notes-in-a-slack-thread-introducing-promptcache-3edff7aedd18
url
https://medium.com/@vitiya99/stop-treating-ai-prompts-like-notes-in-a-slack-thread-introducing-promptcache-3edff7aedd18
canonical_url
https://medium.com/@vitiya99/stop-treating-ai-prompts-like-notes-in-a-slack-thread-introducing-promptcache-3edff7aedd18
author_url
https://medium.com/@vitiya99
status
ok
fetched_at
2026-07-10 19:15:58