Skip to main content
skill CX Codex

content-modeling-best-practices — Claude Code skill: content modeling

Guides your agent through content type design in headless CMS: what to reference, what to embed, how to stop duplicating data.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add sanity-io/agent-toolkit --skill content-modeling-best-practices -a claude-code
Open on GitHub

What content-modeling-best-practices does

The skill hands your agent a set of principles for content schemas. Four of them anchor everything: content is data, not pages; one source of truth; the model should survive channels that don't exist yet; and the editor creating content comes first.

Guidance is split across four files in references/: separating content from presentation, choosing between references and embedded objects, reuse patterns, and taxonomies — flat, hierarchical, faceted. The agent pulls the file that matches the decision in front of it rather than loading every topic.

The concepts apply to any headless CMS, with Sanity-specific implementation notes where they matter. Reach for it when a schema has already drifted: the same fields copied across three content types, or a structure that mirrors page layout instead of meaning. This is design and refactoring help, not schema code generation.

What it helps with

  • decide between a reference and an embedded object
  • separate content from presentation in an existing schema
  • stop duplicating copy across content types
  • plan a model for multi-channel delivery
  • pick between flat, hierarchical and faceted classification

Example prompts for the agent

  • Help me design content types for a blog: where do references make sense, where do embedded objects?
  • Review my schema — is it too page-shaped?
  • How do I reuse an author block across articles and case studies without duplication?

How to install content-modeling-best-practices

1Skills CLI (Vercel)

npx skills add sanity-io/agent-toolkit --skill content-modeling-best-practices -a claude-code

2Manually: put the files in place

~/.claude/skills/content-modeling-best-practices/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/content-modeling-best-practices/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about content-modeling-best-practices

How do I install content-modeling-best-practices in Claude?

Run npx skills add sanity-io/agent-toolkit --skill content-modeling-best-practices -a claude-code. The skill lands at ~/.claude/skills/content-modeling-best-practices/SKILL.md.

What does content-modeling-best-practices do?

It gives the agent principles for structured content modeling: separation of concerns, references versus embedding, content reuse, and taxonomy design.

Is this skill Sanity-only?

No. The concepts work for any headless CMS, though the text includes Sanity-specific implementation notes.

Source text

SKILL.md · MIT
---
name: content-modeling-best-practices
description: Structured content modeling guidance for schema design, content architecture, content reuse, references versus embedded objects, separation of concerns, and taxonomies across Sanity and other headless CMSes. Use this skill when designing or refactoring content types, deciding field shapes, debating reusable versus nested content, planning omnichannel content models, or reviewing whether a schema is too page-shaped or presentation-driven.
---

# Content Modeling Best Practices

Principles for designing structured content that's flexible, reusable, and maintainable. These concepts apply to any headless CMS but include Sanity-specific implementation notes.

## When to Apply

Reference these guidelines when:
- Starting a new project and designing the content model
- Evaluating whether content should be structured or free-form
- Deciding between references and embedded content
- Planning for multi-channel content delivery
- Refactoring existing content structures

## Core Principles

1. **Content is data, not pages** — Structure content for meaning, not presentation
2. **Single source of truth** — Avoid content duplication
3. **Future-proof** — Design for channels that don't exist yet
4. **Editor-centric** — Optimize for the people creating content

## References

Start with the reference that matches the modeling decision in front of you, instead of loading every topic at once. See `references/` for detailed guidance on specific topics:
- `references/separation-of-concerns.md` — Separating content from presentation
- `references/reference-vs-embedding.md` — When to use references vs embedded objects
- `references/content-reuse.md` — Content reuse patterns and the reuse spectrum
- `references/taxonomy-classification.md` — Flat, hierarchical, and faceted classification

© sanity-io · MIT · sanity-io/agent-toolkit

Similar skills

Everything for Marketing and content →

From the same set9

sanity-best-practices Sanity's own rules for an AI agent working on a Sanity codebase: schemas, GROQ, TypeGen, visual editing, migrations and framework wiring. Useful the moment the agent touches your content layer. CX Codex +1 31,800installs sanity-migration Plans and executes content migrations from legacy CMS platforms into Sanity. Guides schema mapping, Portable Text conversion, asset uploads, and cutover checks. CX Codex +1 22,200installs seo-aeo-best-practices A skill with SEO and AEO guidance: metadata, Open Graph, sitemaps, robots.txt, hreflang, JSON-LD and EEAT. Useful while you build pages and want search engines and AI answers to pick them up. CX Codex +1 7,300installs content-experimentation-best-practices This skill guides content A/B test planning, metric selection, and result analysis. Use it when working with CMS-managed variants or frontend experiments. CX Codex +1 3,800installs portable-text-serialization A skill that shows the agent how to render and serialize Portable Text to React, Svelte, Vue, Astro, HTML, Markdown and plain text. CX Codex +1 2,900installs portable-text-conversion Turns HTML and Markdown into Portable Text blocks for Sanity. Useful when migrating content off a legacy CMS or building an import pipeline. CX Codex +1 2,700installs sanity-studio-upgrade The skill inspects your repo and reports only the breaking changes that actually apply to it. Handy when your Studio sits several majors behind. CX Codex +1 524installs Sanity Connects your agent to a Sanity project: content, datasets, releases and schemas. Useful when CMS edits happen in chat instead of Studio. CX Codex +1 ★ 194repo stars

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor