Brand Packs
A brand pack bundles your organization's template file, extracted layouts, archetype mappings, and assets into a versioned unit that the render engine applies automatically during preflight and rendering.
What a Brand Pack Contains
| Component | Description |
|---|---|
| Template file | A .pptx or .potx file that provides slide masters and layouts |
| Compiled tokens | Color palette, font families, and spacing rules extracted from the template |
| Layouts | Each slide master layout with placeholder types, counts, and geometry |
| Archetypes | Mappings from semantic slide types (e.g. title-body, kpi-grid) to specific template layouts, inferred from placeholder structure and naming |
| Assets | Logos, images, or other binary files associated with the brand pack |
Creating a Brand Pack
Upload a template file to the brand pack API:
curl -X POST https://api.paperjsx.com/api/v2/brand-packs \
-H "Authorization: Bearer pj_live_YOUR_KEY" \
-F "name=Acme Corp" \
-F "file=@acme-template.pptx"
The server parses the template, extracts layouts and placeholder geometry, infers archetype mappings, and stores a compiled version. The response includes the brand pack ID and its first version.
Versioning
Each upload creates a new version of the brand pack. Versions are numbered sequentially. Key version fields:
version_number-- integer, starting at 1status-- compilation state of the versionplaceholder_coverage-- percentage of layouts with recognized placeholder typesmissing_placeholder_count-- placeholders the engine could not classifytemplate_support_level-- how well the template maps to the V2 slide type setcertified-- whether this version has been manually verified
Only one version is active at a time (active_version_id on the brand pack record). Renders that reference a brandPackId without a specific brandPackVersionId use the active version.
Using Brand Packs in Renders
Pass brandPackId (and optionally brandPackVersionId) to preflight or render requests:
{
"sourceSchema": "protocol_v2",
"brandPackId": "bp_abc123",
"document": {
"version": "2.0",
"title": "Branded Deck",
"slides": [...]
}
}
The engine resolves the brand pack, applies the template, maps semantic slide types to brand-specific layouts using archetype inference, and includes brand compliance findings in the quality report.
Archetype Inference
When a brand pack version is compiled, the engine analyzes each layout's placeholder families (title, body, chart, table, image) and geometry to infer which semantic slide types it can support. Inference sources include:
- Keyword matching -- layout name contains terms like "comparison", "timeline", "chart"
- Placeholder geometry -- grid-like arrangements suggest
kpi-gridortombstone-grid - Placeholder family counts -- a layout with title + body placeholders maps to
title-body - Fallback -- layouts that do not match a specific type receive a generic mapping
Brand Compliance
When a brand pack is attached, the preflight quality report includes a brand_compliance section with findings about layout mismatches, missing placeholders, and archetype coverage gaps. These findings feed into the policyResult guardrail decision.
Next Steps
- Render Jobs -- see how brand packs appear on job records
- Review Loop -- approve renders that include brand compliance data
- SDK API Reference --
PresentationSpec.brandfield reference