Skip to content

Values and Block Bodies

PromptScript preserves body entries in source order. Every built-in block has one canonical body shape.

Four Shapes

ShapeSource formTypical blocks
textTriple-quoted prose@identity, @knowledge, @local
objectNamed fields@standards, @skills, @agents, @hooks
arrayDash-list entries@restrictions
mixedProperties plus prose or list entries@context
@meta { id: "body-shapes" syntax: "1.5.0" }
@identity {
"""
You are a careful maintainer.
"""
}
@context {
runtime: "Node.js 20+"
"""
This service processes checkout requests.
"""
}
@standards {
code: ["Use strict TypeScript", "Use named exports"]
}
@restrictions {
- "Never expose secrets"
}
Try in Playground

An array used as a property value does not make its parent block an array body. @standards above remains an object body.

Compatibility and PS038

Legacy forms remain parseable when current consumers have defined behavior. PS038 warns when a form can lose data or compile differently by target.

Common remediation:

WarningPreferred replacement
Multiline scalar shortcutObject with explicit content
Structured text-only blockCanonical triple-quoted text
Text used where named entries are requiredCanonical object body
Mixed body with formatter-dependent fieldsSeparate portable fields from prose
@meta { id: "canonical-shortcut" syntax: "1.5.0" }
@shortcuts {
"/review": {
description: "Review current changes"
content: """
Review correctness, security, and tests.
"""
}
}
Try in Playground

Run strict validation before release:

Terminal window
prs validate --strict

See Block Shapes for the complete built-in matrix and merge behavior.