Skip to main content

write-parser

Write Groovy parsers and import scripts that map source data formats (XML, JSON, CSV, etc.) into the Quadient Inspire Migration Model. Use this skill when asked to create, generate, update, or fix a parser, importer, field mapping, or source-to-model transformation for migration-examples.

Source facts

Repository
quadient/migration-stack
Last source activity
June 29, 2026 at 11:54
Detected SKILL.md language
English
Stars
8
Forks
3

Install options

The review-first prompt is selected by default. You can switch to a direct command or download a local copy.

Review the source files

Read SKILL.md and any companion files shown by SkillsMP before deciding whether to install.

File Explorer
2 files

Showing SKILL.md

SKILL.md
Source instructions · Read-only preview
name
write-parser
description
Write Groovy parsers and import scripts that map source data formats (XML, JSON, CSV, etc.) into the Quadient Inspire Migration Model. Use this skill when asked to create, generate, update, or fix a parser, importer, field mapping, or source-to-model transformation for migration-examples.
compatibility
Requires Quadient Inspire Designer or Interactive for deployment of parsed output
# Parser Development You help with migrations from various CCM (Customer Communications Management) software to Quadient Inspire by creating parsing scripts that transform source data into the Migration Model. ## Responsibilities - **Input format analysis** - Analyze source format structure and map it to the Migration Model - **Parsing script creation** - Generate Groovy scripts that transform source data into the Migration Model ## Key Guidelines ### What You Should Do 1. **Analyze source formats** - Understand structure, data types, relationships, and formatting 2. **Map to Migration Model** - Align source concepts with target model objects (Variables, Styles, Document Objects, etc.) 3. **Generate parsing scripts** - Create Groovy code using the migration library API ### What You Should NOT Do 1. **Do not generate or modify configuration files** - These are user-managed 2. **Do not invent source data** - Work only with provided samples ## Workflow Follow this process for every parsing script: 1. **Analyze** - Understand the source format structure and data 2. **Map** - Identify how source elements map to Migration Model objects 3. **Generate** - Create the parsing script using the migration library API 4. **Test** - Run the script against sample data 5. **Fix** - Resolve any runtime errors iteratively 6. **Validate** - Verify output structure matches expected Migration Model **⚠️ Critical:** Always run generated scripts and fix runtime errors before considering the task complete. Do not stop at script generation—test execution is mandatory. ### Common Runtime Issues Watch out for these recurring problems: - Null pointer exceptions when accessing optional elements - Type mismatches (String vs Integer, etc.) - Missing or incorrect API method calls - Groovy syntax errors (closures, method references) - Incorrect XML/JSON path expressions ## Input Requirements For effective analysis, the user should provide: - **Format name** (e.g. "DocBook", "AzureAI", etc.) - **Sample content** (XML, JSON, CSV, or other format files) - **Approach** (only analysis, basic script with only e.g. paragraphs and text/paragraph styles, or complete script) - **Context** (optional: known quirks, special handling requirements) ## Output Format The Migration Model (target format) is the common intermediate representation. All source formats are parsed into this model, which consists of: - **Variables** - Data fields with types - **Text/Paragraph Styles** - Formatting definitions - **Document Objects** - Templates, Pages, Blocks, Sections - **Display Rules** - Conditional logic - **Images** - Visual resources ## References - [Migration Library API](references/MIGRATION-API.md) - Complete API documentation for builders, repositories, and model objects - If present, consult [Examples & Patterns](references/EXAMPLES.md) for proven parsing patterns and troubleshooting tips
View on GitHub