Skip to content

Populating content

The /populate-site skill populates a blank portal site with content by analyzing source material — PDFs, websites, and contextual notes — and generating valid portal content files. It ships inside the published @drawnagency/authoring package and is linked into each client repo’s .claude/skills/ by postinstall.

Run it from the client repo root in Claude Code. The portal monorepo is not required.

  • pnpm install has been run in the client repo (installs @drawnagency/authoring and links skills via postinstall).
  • The repo has the template structure: src/content/index.json, src/content/site-config.json, and src/content/sections/.
/populate-site <project-path> <sources...> "<context>"
ArgumentDescription
project-pathAbsolute path to the client project directory.
sourcesOne or more PDF file paths and/or URLs to scrape for brand content.
contextQuoted string with industry, aesthetic, or other background context.
/populate-site ~/coldfire-brewing-portal ~/coldfire-ref/brand_standards_2024.pdf https://coldfirebrewing.com "craft brewery in Eugene, Oregon"

The skill runs in six phases:

  1. Gather source material — reads PDFs and fetches URLs to extract brand elements: color palette, typography, logo usage, voice and tone, imagery direction, and any other brand-specific content.

  2. Plan site structure — maps content to section types and produces a section ordering that follows the source material’s structure.

  3. Generate content files — writes section JSON files to src/content/sections/, and updates index.json and site-config.json with the brand’s colors, fonts, and site name.

  4. Process images — downloads available images to _ingest/images/, then runs:

    Terminal window
    pnpm exec authoring process-images --project .

    This produces WebP variants and assigns each image a 16-char hash ID. Section files are updated with the resulting imageId references.

  5. Validate — runs:

    Terminal window
    pnpm exec authoring validate --project .

    If errors are reported, the skill fixes the offending files and re-validates until clean.

  1. Review generated section files in src/content/sections/ and adjust as needed.

  2. Provide any images that could not be extracted — images embedded in PDF files (logos, patterns, label designs) cannot be extracted programmatically and must be supplied manually from original design files. Drop them into _ingest/images/ and re-run:

    Terminal window
    pnpm exec authoring process-images --project .
  3. Commit and push when the content looks right.

  • The _ingest/ directory is gitignored. Only processed images in assets/images/ get committed to the repository.
  • Images downloaded from websites are staged automatically; PDF-embedded images require manual extraction.
  • Run pnpm exec authoring validate --project . at any time to check content files for schema errors.