template-library · Content Template Library

A skill for saving, reusing, and managing content templates: proven content structures are saved as templates with {{variable}} placeholders auto-extracted, then reapplied by filling in the variables. Templates are organized by platform category, with version management and usage counts. All file and index operations run deterministically through script subcommands (save / use / list / edit / delete / get).
Example invocation: "Save this post as a template under the Xiaohongshu category."
Full brief
Positioning
template-library is the central hub for saving, reusing, and managing personal content templates: successful content structures are preserved as reusable templates and applied directly next time. It manages the user's own accumulated templates — not generic marketing frameworks.
Core capabilities
- 6 operations: save / use / list / edit / delete / get.
- Template structure analysis: before saving, the LLM reads the source content, identifies fixed structure vs. variable regions, and rewrites concrete values as
{{variable}}placeholders; the script extracts the variable list, writes the file, and registers the index. - Platform categories: templates are filed under xiaohongshu / weibo / douyin / zhihu / wechat / x / general.
- Script-level guarantees: same-name saves are rejected by default (needs
--forceto overwrite); unfilled variables inusekeep their{{placeholder}}with a stderr warning;deleteis dry-run by default and only deletes with--apply; all writes are atomic so index and template files stay consistent;useauto-increments usage_count. - Profile-aware: with a profile, saves auto-bind to it, listing prioritizes the current profile's templates, and use loads the profile style for tone adaptation.
Workflow
- Parse intent and route to save / use / list / edit / delete / get
- Save: LLM analyzes source → rewrites
{{var}}placeholders → script extracts variables, writes file, registers index - Use: LLM derives fill values per variable → script substitutes and increments usage count
- Results returned in a uniform Markdown format
Inputs & outputs
| Input | Notes |
|---|---|
| action | Required — save / use / list / edit / delete / get |
| template_name | Required for save / use / edit / delete / get |
| source_file / source_text | For save — one of the two, the content to templatize |
| category | Optional — platform category |
| variables / topic | For use — variable values and topic |
Output: save confirmation (extracted structure + variable list), template application result, template list, and other operation outputs.
Boundaries with adjacent skills
- post-formatter: provides generic marketing frameworks (PAS / AIDA / BAB); template-library manages the user's own accumulated templates.
- social-content: generates content from scratch; template-library replicates structure from existing templates.
Fit
- Locking in a proven content structure for repeated reuse
- Adapting one structure across platforms quickly
- Standardizing team output templates
- Content assets that need versioning and usage stats
Before you start
- For save, prepare a reusable piece of content (text or file path).
- Decide the template's platform category.
- Delete is dry-run by default; add
--applyonly after confirming the preview.
template-library is part of the Aiglade Skill library. Invoke it from the Aiglade chat box in plain language.