Inferensys

Prompt

Migration Guide Prerequisites Checklist Prompt

A practical prompt playbook for generating a verifiable prerequisites checklist for version-to-version migration guides, designed for technical writers and release managers.
Developer doing prompt engineering on laptop, prompt variations visible on screen, casual coding session.
PROMPT PLAYBOOK

When to Use This Prompt

Define the exact job-to-be-done, required inputs, and boundaries for the Migration Guide Prerequisites Checklist Prompt.

This prompt is for technical writers, release managers, and platform engineers who need to generate the 'Before You Begin' or 'Prerequisites' section of a version-to-version migration guide. Its job is to transform a structured inventory of breaking changes and target version metadata into a concrete, verifiable checklist of preconditions that consumers must satisfy before executing the first migration step. Use it when you have a finalized, reviewed list of breaking changes and need to ensure downstream consumers do not skip environment preparation, backup steps, or dependency upgrades that would cause a migration to fail silently or catastrophically.

The prompt requires two structured inputs to function reliably: a [BREAKING_CHANGE_INVENTORY] containing every documented breaking change with its affected surface, severity, and required consumer action, and a [TARGET_VERSION_INFO] block specifying the target version number, minimum required runtime or platform versions, and any new mandatory dependencies. Without these inputs, the prompt will hallucinate prerequisites or omit critical preconditions. The output is a markdown checklist where every item is actionable (the consumer can perform it and verify completion) and traceable to a specific breaking change or version requirement. For example, if a breaking change removes a deprecated authentication method, the checklist must include a step to verify that all clients use the replacement method before upgrading.

Do not use this prompt to discover breaking changes, write the step-by-step migration instructions, or draft the full migration guide. It is a focused tool for the prerequisites section only. If your breaking change inventory is incomplete or unverified, stop and complete that work first. In high-risk environments—such as database migrations, security-sensitive upgrades, or regulated infrastructure—pair this prompt's output with a human review gate and require evidence that each prerequisite has been satisfied before the migration proceeds. The next step after generating the checklist is to validate it against the full breaking change inventory using a completeness audit prompt, then wire it into your migration runbook or release automation.

PRACTICAL GUARDRAILS

Use Case Fit

Where the Migration Guide Prerequisites Checklist Prompt delivers value and where it introduces risk.

01

Good Fit: Structured Release Process

Use when: your team follows a versioned release cadence with a known diff between versions. The prompt excels at converting structured inputs (changelogs, API diffs, dependency manifests) into a verifiable, step-by-step prerequisites section. Guardrail: Feed the prompt a machine-readable diff or changelog fragment rather than asking it to infer prerequisites from a version number alone.

02

Bad Fit: Undocumented or Exploratory Upgrades

Avoid when: the source and target environments are not fully known, or the migration path is being discovered for the first time. The prompt will hallucinate plausible but incorrect prerequisites (e.g., fictional minimum versions or non-existent config keys). Guardrail: Use a discovery prompt or manual audit first; only apply this checklist prompt once the breaking change inventory is confirmed.

03

Required Inputs: Version Diff and Dependency Graph

What to watch: without explicit input on what changed, the model defaults to generic advice ('back up your data'). Guardrail: Provide [SOURCE_VERSION], [TARGET_VERSION], a [BREAKING_CHANGE_LIST], and a [DEPENDENCY_MANIFEST]. The harness should reject execution if these fields are empty or contain only placeholder text.

04

Operational Risk: Unverifiable Prerequisites

What to watch: the model may generate prerequisites that sound reasonable but cannot be tested (e.g., 'ensure system is stable'). Guardrail: Add an eval step that checks every prerequisite against a verifiability criterion—each item must include a specific command, version check, or configuration validation that returns a boolean result.

05

Operational Risk: Ordering Dependencies

What to watch: the model may list prerequisites in a logical but incorrect order, causing consumers to attempt a config change before the required version bump. Guardrail: Include explicit ordering constraints in the prompt template and validate the output sequence against a dependency graph. Flag any prerequisite that references a state not yet achieved by a prior step.

06

Bad Fit: Consumer-Facing Communication

Avoid when: the output is intended for external consumers without technical review. The checklist is an internal engineering artifact; publishing it directly may expose internal version details, incomplete workarounds, or untested commands. Guardrail: Route the output through a human review step and a separate communication prompt before any customer-facing release.

PROMPT PLAYBOOK

Copy-Ready Prompt Template

A reusable prompt for generating a verifiable prerequisites checklist from release artifacts before drafting migration steps.

This prompt template is designed to be wired into a documentation pipeline. It takes structured release artifacts—such as changelogs, dependency manifests, and configuration diffs—and produces a prerequisites section that is actionable and verifiable. The output is not a narrative guide but a structured checklist where every item can be confirmed or rejected by a downstream consumer.

text
You are a technical documentation engineer preparing a migration guide.

Your task is to produce a prerequisites checklist for upgrading from [SOURCE_VERSION] to [TARGET_VERSION] of [PRODUCT_NAME].

Use the following inputs:
- Release changelog: [CHANGELOG]
- Dependency manifest diff: [DEPENDENCY_DIFF]
- Configuration schema changes: [CONFIG_DIFF]
- Deprecated surface inventory: [DEPRECATED_SURFACES]
- Known issues list: [KNOWN_ISSUES]

For each prerequisite, include:
1. A clear, imperative action (e.g., "Upgrade the database client library to v3.2 or later").
2. The reason this action is required (e.g., "The v2.x client cannot parse the new wire protocol introduced in [TARGET_VERSION]").
3. A verifiable check (e.g., "Run `npm list db-client` and confirm the version is >= 3.2.0").
4. A category: [ENVIRONMENT_PREP | PERMISSIONS | DEPENDENCY_UPGRADE | CONFIG_CHANGE | DATA_BACKUP | DEPRECATION_CHECK | OTHER].

Constraints:
- Every prerequisite must be traceable to a specific entry in the provided artifacts.
- Do not invent prerequisites that are not supported by the inputs.
- If a prerequisite cannot be verified by the consumer, flag it with [VERIFICATION_GAP].
- Group prerequisites by category and order them by dependency (e.g., environment prep before dependency upgrades).
- If a prerequisite has a known workaround or is optional, mark it clearly.

Output format:
```json
{
  "source_version": "[SOURCE_VERSION]",
  "target_version": "[TARGET_VERSION]",
  "prerequisites": [
    {
      "action": "string",
      "reason": "string",
      "verification": "string",
      "category": "string",
      "required": true,
      "workaround": "string or null",
      "source_artifact": "string"
    }
  ],
  "verification_gaps": ["string"]
}

To adapt this template, replace each square-bracket placeholder with data extracted from your release pipeline. The [CHANGELOG] should be the structured diff between the two versions, not a marketing summary. The [DEPRECATED_SURFACES] input should come from a prior deprecation flagging step. Before shipping, run the output through a validation harness that cross-references every prerequisite against the source artifacts and flags any item that cannot be traced back to a specific change. For high-risk migrations, route the generated checklist through a human reviewer who can confirm that no critical prerequisite was omitted.

IMPLEMENTATION TABLE

Prompt Variables

Inputs the prompt needs to produce a reliable, actionable prerequisites checklist. Validate each input before assembly to prevent missing preconditions or unverifiable steps.

PlaceholderPurposeExampleValidation Notes

[SOURCE_VERSION]

The exact version the user is migrating from

v2.4.1

Must match a real, released version tag in the changelog or package registry. Reject if null or 'latest'.

[TARGET_VERSION]

The exact version the user is migrating to

v3.0.0

Must be greater than [SOURCE_VERSION] per semver. Reject if version does not exist in the release index.

[BREAKING_CHANGE_INVENTORY]

Structured list of every documented breaking change between versions

JSON array of change objects with severity, surface, and required action

Must be non-empty. Validate each entry has a source link to a commit, changelog, or spec diff. Reject if inventory is missing or empty.

[PLATFORM_CONTEXT]

Target runtime, language, and deployment environment

Node.js 20.x, AWS Lambda, arm64

Used to filter prerequisites that are platform-specific. Accept a structured object or validated enum. Null allowed if guide is platform-agnostic.

[DEPENDENCY_MANIFEST]

Current dependency versions from the consumer's lockfile or manifest

package.json + package-lock.json content

Parse to extract exact versions of the primary package and its peers. Reject if unparseable. Used to flag minimum version requirements.

[CONFIGURATION_SNAPSHOT]

Current configuration or environment variables in use

YAML config block or .env file content

Parse to detect deprecated config keys. Null allowed if no config migration is required. Warn if snapshot is stale (older than [SOURCE_VERSION] release date).

[AUTH_SCOPE]

The permission model or scopes required for the migration

admin:write, repo:delete

Validate against the target version's auth documentation. Reject if a required scope is not documented. Null allowed for zero-permission upgrades.

[ROLLBACK_PLAN_REF]

Link or identifier for the approved rollback procedure

runbook/rollback-v3.md

Must resolve to an existing document or be explicitly marked as 'not required' by a release manager. Reject if null for a breaking-change migration.

PROMPT PLAYBOOK

Implementation Harness Notes

How to wire the Migration Guide Prerequisites Checklist prompt into a documentation pipeline with validation, retries, and human review gates.

The prerequisites checklist prompt is designed to sit inside a documentation generation or review pipeline, not as a standalone chat interaction. The typical integration point is after a breaking change enumeration has been produced and before the full migration guide is drafted. The prompt receives structured inputs—version numbers, dependency manifests, configuration schemas, and the breaking change inventory—and outputs a structured prerequisites section that downstream guide assembly prompts can consume. Because missing or incorrect prerequisites cause real consumer breakage, the harness must enforce validation, completeness checks, and human review before the output reaches a published guide.

Wire the prompt into your pipeline as a discrete step with a defined input contract and output schema. Inputs should include: [CURRENT_VERSION] and [TARGET_VERSION] as semver strings; [BREAKING_CHANGE_INVENTORY] as a structured list of changes with affected surfaces; [DEPENDENCY_MANIFEST] as parsed package.json, requirements.txt, or equivalent; [CONFIG_SCHEMA] as the full configuration reference for both versions; [AUTH_SCOPE_DIFF] if permissions or scopes changed; and [ENVIRONMENT_REQUIREMENTS] such as runtime versions, OS constraints, or infrastructure prerequisites. Output schema should enforce a JSON structure with fields: minimum_version_requirements, required_permissions, dependency_upgrades, configuration_backups, environment_preparation, and pre_flight_checks. Each field must contain an array of actionable items with description, verification_command (a runnable check), and blocking (boolean indicating whether failure prevents migration). Validate the output programmatically: every verification_command must be non-empty and syntactically plausible for the target environment; every prerequisite must reference at least one breaking change from the input inventory or a version-specific requirement from the dependency manifest; and no prerequisite should be purely advisory without a verifiable check.

Model choice and retry strategy matter here. Use a model with strong instruction-following and structured output support (GPT-4o, Claude 3.5 Sonnet, or equivalent). Set response_format to JSON schema mode if the provider supports it, or use a strict parser with a retry loop. On validation failure, feed the validation errors back into a retry prompt that includes the original inputs, the failed output, and the specific validation failures. Limit retries to 3 attempts, then escalate to a human reviewer queue with the partial output and error log. Logging and observability should capture: the prompt version hash, input hashes, output schema compliance status, validation pass/fail per field, retry count, and final reviewer decision. This audit trail is essential when a consumer reports a missing prerequisite—you can trace whether the prompt omitted it, validation missed it, or a human reviewer overrode it. Human review is mandatory before publication. Present the reviewer with the structured checklist, the source breaking change inventory, and a diff of any items that failed validation or were added during retry. The reviewer should confirm that every breaking change with a prerequisite has a corresponding checklist item and that no verification command would cause harm if executed. For high-risk migrations involving data loss potential or auth scope changes, add a second reviewer or a required sign-off gate in your documentation CMS.

When this prompt is not enough, you need product code or additional tooling. If your migration involves database schema changes, the verification commands should invoke actual schema comparison tools, not just echo commands. If your dependency upgrades require resolving transitive conflicts, integrate a dependency resolver that runs before the prompt and feeds its output into [DEPENDENCY_MANIFEST]. If your configuration backups involve secrets, the prompt should reference your secrets management tooling by name but never handle secret values directly. The prompt produces a checklist for humans and automation to execute—it does not execute the checks itself. For fully automated migration pipelines, pair this prompt's output with a workflow engine that runs each verification_command, captures results, and blocks progression on blocking: true failures. The prompt's job is to ensure completeness and actionability; the harness's job is to enforce correctness and safety before any consumer sees the guide.

IMPLEMENTATION TABLE

Expected Output Contract

Defines the shape, types, and validation rules for the prerequisites checklist produced by the prompt. Use this contract to parse, validate, and integrate the output into a migration guide pipeline.

Field or ElementType or FormatRequiredValidation Rule

prerequisites

Array of objects

Schema check: array length >= 1. Each item must match the prerequisite_item schema.

prerequisite_item.category

String enum

Enum check: value must be one of 'version_requirement', 'permission', 'dependency', 'backup', 'environment_prep', 'configuration', 'data_migration', 'other'.

prerequisite_item.description

String

Parse check: non-empty string. Must contain an actionable verb phrase. Must not exceed 280 characters.

prerequisite_item.verification_method

String

Parse check: non-empty string. Must describe a verifiable command, check, or observable state. Examples: 'Run kubectl version', 'Check IAM role exists'.

prerequisite_item.required

Boolean

Type check: must be true or false. If false, a conditional_trigger field must be present.

prerequisite_item.conditional_trigger

String or null

Null check: allowed when required is true. When required is false, must be a non-empty string describing the condition that makes this prerequisite mandatory.

prerequisite_item.estimated_effort_minutes

Integer or null

Range check: if provided, must be an integer between 1 and 1440. Null allowed when effort is unknown.

metadata.generated_at

ISO 8601 timestamp

Format check: must parse as a valid ISO 8601 datetime string. Represents when the checklist was generated.

PRACTICAL GUARDRAILS

Common Failure Modes

What breaks first when generating migration guide prerequisites and how to guard against it.

01

Missing Implicit Prerequisites

Risk: The model lists only explicitly stated requirements from source docs and omits implicit prerequisites such as 'git installed', 'shell access', or 'network connectivity to the package registry'. Guardrail: Provide a static base checklist of universal prerequisites in the system prompt and instruct the model to merge it with version-specific items.

02

Unverifiable Prerequisites

Risk: The model generates vague steps like 'ensure your environment is stable' or 'have sufficient permissions' without specifying how to verify them. Guardrail: Add an output constraint requiring every prerequisite to include a specific verification command (e.g., node --version) or a checkable state.

03

Version Drift in Dependency Specs

Risk: The model hallucinates minimum version numbers or copies them from outdated training data, causing consumers to install incompatible versions. Guardrail: Inject the live package.json, requirements.txt, or composer.json into the context window and instruct the model to extract exact version pins only from that source.

04

Incorrect Execution Order

Risk: The model lists prerequisites in a logical but operationally wrong order (e.g., running database migrations before backing up the schema). Guardrail: Use a few-shot example demonstrating the correct topological sort of operations (backup -> upgrade -> migrate -> verify) and instruct the model to validate ordering against dependency chains.

05

Omitting Rollback Prerequisites

Risk: The checklist focuses only on forward-migration steps and ignores preconditions for a safe rollback, such as 'take a snapshot' or 'export current config'. Guardrail: Require a dedicated 'Rollback Prerequisites' subsection in the output schema and validate its presence in the evaluation harness.

06

Environment-Specific Assumptions

Risk: The model assumes a specific OS, shell, or cloud provider (e.g., apt-get commands on a Mac) without detecting the target environment. Guardrail: Include a required [TARGET_ENVIRONMENT] input variable and condition the prompt to generate OS-specific blocks or flag unsupported steps.

IMPLEMENTATION TABLE

Evaluation Rubric

Use this rubric to test the quality of the generated prerequisites checklist before shipping. Each criterion targets a specific failure mode common in migration guide authoring.

CriterionPass StandardFailure SignalTest Method

Actionability

Every prerequisite is a single, verifiable action (e.g., 'Upgrade Node.js to >=18.0.0')

Prerequisite is a vague statement (e.g., 'Ensure environment is ready') or a non-verifiable condition

Parse each prerequisite; reject if it cannot be converted into a boolean check or version comparison

Version Grounding

All minimum version requirements match the [SOURCE_CHANGELOG] and [BREAKING_CHANGE_INVENTORY]

A version number appears that is not documented in the source material or is contradicted by it

Cross-reference each version string against the source documents; flag any orphaned version

Permission Completeness

Every required IAM role, API scope, or access right is listed with its exact identifier

A step says 'ensure you have admin access' without specifying the exact permission or scope

Check that each permission entry contains a machine-readable identifier (e.g., 'roles/cloudsql.admin')

Dependency Coverage

All dependencies flagged in [BREAKING_CHANGE_INVENTORY] appear as upgrade prerequisites

A breaking change requires a dependency upgrade, but the prerequisite section omits it

Diff the prerequisite list against the dependency column in the breaking change inventory; flag missing entries

Backup Step Presence

A backup or state-capture step is included for any prerequisite that mutates state (e.g., database migrations)

A destructive prerequisite (e.g., 'Run the schema migration script') has no preceding backup instruction

Scan for mutation verbs (run, migrate, upgrade, delete); assert a backup step precedes each one

Verification Criteria

Each prerequisite includes a concrete verification command or check (e.g., 'Run node --version')

A prerequisite ends without telling the user how to confirm it is satisfied

Check that each prerequisite block contains a code snippet or explicit check instruction

Ordering Logic

Prerequisites are ordered by dependency: environment prep, then dependency upgrades, then config changes, then data migrations

A config change appears before the dependency upgrade that enables the new config key

Validate the sequence against a dependency graph derived from the breaking change inventory

Rollback Warning

Any prerequisite that cannot be easily reversed includes a rollback warning and link to the rollback plan

An irreversible step (e.g., data format conversion) is presented without a caution or rollback reference

Scan for irreversibility keywords (convert, migrate data, drop); assert a rollback reference exists

ADAPTATION OPTIONS

Adapt This Prompt

How to adapt

Use the base prompt with a single migration guide draft and manual review. Replace strict schema validation with a simple checklist format. Accept bulleted prerequisites without requiring verifiable commands.

Prompt modification

Remove the [OUTPUT_SCHEMA] block and replace with: Return a markdown checklist where each item starts with '- [ ]'. Drop the [CONSTRAINTS] section requiring actionable verification steps.

Watch for

  • Prerequisites that sound correct but can't be executed (e.g., "ensure database is backed up" without specifying the backup command)
  • Missing version boundaries when the guide covers multiple upgrade paths
  • Overly broad environment preparation steps that skip OS-specific or cloud-specific details
Prasad Kumkar

About the author

Prasad Kumkar

CEO & MD, Inference Systems

Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.

His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.