Skip to main content

Knowledge > Runbooks > Content Ops > Generate Theological-Lens-Specific Content

Generate Theological-Lens-Specific Content

Generate sermon illustrations tailored to a specific theological tradition (lens). ITW serves pastors across 17 traditions plus a universal lens. Use this runbook to build out a lens that has sparse coverage, or when onboarding a denomination's pastors as a new audience segment.

Prerequisites

  • Access to sermon-illustrations/scripts/ directory
  • Claude CLI (claude -p) available in the shell
  • Supabase MCP or direct DB access
  • Target theological lens ID from sai_theological_lenses

Background: The 18 Theological Lenses

SELECT id, name, tradition FROM sai_theological_lenses ORDER BY id;

There are 18 lenses: 17 named traditions (Reformed, Wesleyan/Arminian, Lutheran, Catholic, Pentecostal/Charismatic, Anglican/Episcopal, Baptist, Eastern Orthodox, Anabaptist/Mennonite, Adventist, Evangelical Free, Mainline Protestant, Non-denominational Evangelical, Messianic Jewish, Progressive Christian, Quaker, Restoration Movement) plus universal (ID=1, tradition-neutral).

Each lens has distinct hermeneutical emphases that must be respected in generation prompts.

Steps

  1. Check current coverage for the target lens:

    SELECT
    tl.name,
    COUNT(urc.id) AS illustration_count,
    COUNT(CASE WHEN urc.is_public = true THEN 1 END) AS public_count
    FROM sai_theological_lenses tl
    LEFT JOIN unified_rag_content urc
    ON urc.theological_lens_id = tl.id
    AND urc.category = 'illustration'
    WHERE tl.id = [lens_id]
    GROUP BY tl.name;
  2. Compare coverage across all lenses to identify the sparsest:

    SELECT
    tl.id, tl.name,
    COUNT(urc.id) AS illustration_count
    FROM sai_theological_lenses tl
    LEFT JOIN unified_rag_content urc
    ON urc.theological_lens_id = tl.id
    AND urc.category = 'illustration'
    AND urc.is_public = true
    GROUP BY tl.id, tl.name
    ORDER BY illustration_count ASC;
  3. Navigate to the scripts directory:

    cd /c/dev/sermon-illustrations
  4. Unset Claude CLI env vars before spawning:

    unset CLAUDE_CODE_ENTRYPOINT
    unset CLAUDECODE
  5. Run the lens-specific generation script:

    node scripts/generate-lens-content.mjs \
    --lens [lens_id] \
    --count 10 \
    --topics "grace,forgiveness,prayer,discipleship,hope" \
    --dry-run

    Review the dry-run output. Confirm the prompts reflect the tradition's actual hermeneutical approach.

  6. Key tradition-specific emphases to verify in dry-run output:

    LensEmphasis to Check
    ReformedSovereignty of God, total depravity, covenant theology
    Wesleyan/ArminianFree will, prevenient grace, sanctification, entire sanctification
    CatholicSacramental theology, Tradition alongside Scripture, Marian references
    PentecostalHoly Spirit gifts, experiential faith, divine healing
    LutheranLaw/Gospel distinction, justification by faith alone, simul justus et peccator
    Eastern OrthodoxTheosis, liturgical rhythm, Church Fathers, apophatic theology
    AnabaptistDiscipleship, peace/nonviolence, community accountability
  7. Generate without dry-run:

    node scripts/generate-lens-content.mjs \
    --lens [lens_id] \
    --count 10
  8. Review for theological accuracy — this is the highest-risk step:

    • Have someone familiar with the tradition review at least 30% of generated illustrations.
    • Flag illustrations that misrepresent the tradition's position on key doctrines.
    • Do NOT insert theologically inaccurate content — it damages trust with pastors of that tradition.
  9. Insert approved illustrations:

    INSERT INTO unified_rag_content (
    category, title, content, scripture_reference,
    theological_lens_id, topic_tags, is_public, source, created_at, updated_at
    ) VALUES (
    'illustration',
    '[Title]',
    '[Content]',
    '[Reference]',
    [lens_id],
    ARRAY['[topic1]', '[topic2]'],
    true,
    'generated',
    now(),
    now()
    );

Coverage Target per Lens

Aim for at least 50 public illustrations per lens for the 5 largest traditions (Reformed, Wesleyan, Catholic, Baptist, Pentecostal), and at least 20 for the remaining lenses.

Verification

SELECT COUNT(*) AS public_illustrations
FROM unified_rag_content
WHERE theological_lens_id = [lens_id]
AND category = 'illustration'
AND is_public = true;

Test on ITW by filtering illustrations by the lens and confirming new content appears.

See Also