Commit Graph

39 Commits

Author SHA1 Message Date
kennethreitz 6c4c23a83e Implement major performance optimizations (Phase 1)
Optimization #2: Replace O(n) verse filtering with cached methods
- Replace manual filtering loops with bible.get_verses_by_book_chapter()
- Replace chapter filtering with bible.get_chapters_for_book()
- 13 replacements in server.py
- Expected: 80-95% faster book/chapter pages after first access

Optimization #3: Build slug index for O(1) resource lookups
- Create pre-built slug indexes for all 38 resource dictionaries
- Replace O(n) linear search with O(1) hash lookup
- Add find_resource_by_slug() function to data module
- Expected: 95% faster resource page lookups

Combined expected improvement: 50-80% overall performance gain

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-27 12:00:13 -05:00
kennethreitz 7d1f7a65ee Align Song of Solomon book data with verses file naming
Rename book data file and update all references to use "Solomon's Song"
(matching verses-1769.json) instead of "Song of Solomon".

Changes:
- Rename song_of_solomon.json → solomons_song.json
- Update "name" field: "Song of Solomon" → "Solomon's Song"
- Update all verse references to use "Solomon's Song X:Y" format

This ensures the book data name matches the verses file exactly,
eliminating the need for normalization redirects.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-27 09:27:26 -05:00
kennethreitz f2a079f4b8 Replace Song of Solomon content with new comprehensive version
Updated all sections of the Song of Solomon book data:

- Introduction: Revised to emphasize the Song's unique place in Scripture,
  Hebrew superlative title, dialogue structure, and dual literal/typological
  interpretation following Reformed approach

- Key Themes: Replaced 8 themes with 7 focused themes including goodness of
  marital desire, exclusive devotion, love strong as death, beauty of the
  beloved, seeking and finding, the garden enclosed, and Christ/church typology

- Key Verses: Simplified to 7 core verses with reference and text only

- Outline: Updated to 6 sections tracking the Song's movement from longing
  through consummation to the seal of love

- Historical Context: Expanded on Solomonic era and wisdom literature context

- Literary Style: Enhanced treatment of lyric poetry, wasf genre, imagery,
  and Hebrew linguistic complexity

- Theological Significance: Four-paragraph treatment of creation goodness,
  marital love, bride metaphor, and love's cosmic significance

- Christ in Book: Six-paragraph typological reading showing bridegroom seeking
  bride, delighting in beauty, mutual possession, garden restoration, and
  love conquering death

- Relationship to NT: Four-paragraph treatment of Ephesians 5, Revelation's
  marriage imagery, Jesus as bridegroom, and NT sexual ethics

- Practical Application: Five-paragraph treatment for married couples, singles,
  spiritual dryness, non-transactional love, and meditation on Christ's love

All content maintains theological depth while being more accessible and
clearly structured for the website.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-27 09:14:33 -05:00
kennethreitz 3841fecba6 Expand book introductions for Titus, 2 Timothy, Zechariah, and Philemon
All four books now have comprehensive 2,000+ character introductions:

- Titus (890 → 2,800+ chars): Expanded to cover Cretan culture, Pastoral
  Epistles context, dual emphasis on doctrine and good works, gospel
  counterculture theme, and detailed letter structure

- 2 Timothy (898 → 3,400+ chars): Expanded to emphasize final testament
  nature, contrast between imprisonments, passing the torch theme, guarding
  the gospel deposit, Scripture's inspiration, and finishing well

- Zechariah (1,029 → 3,800+ chars): Expanded to cover post-exilic context,
  eight night visions, messianic prophecies (humble king, pierced one),
  two-part structure (chs 1-8 vs 9-14), and extensive NT quotations

- Philemon (1,090 → 3,600+ chars): Expanded to cover slavery in Roman
  context, gospel doctrines (substitution, imputation, reconciliation),
  Paul's pastoral diplomacy, gospel undermining slavery from within

All introductions now match the depth and comprehensiveness of other
major books (Genesis, Romans, John, Song of Solomon, etc.)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-27 09:03:52 -05:00
kennethreitz 27c59ccd2f Fix italic markdown rendering in resource pages
- Add mdi (markdown inline) filter to resource_index.html template
  to properly render *italic* and **bold** markdown syntax
- Italicize transliterated Hebrew/Greek terms in spirits-and-demons content
- Ensures foreign language terms display with proper emphasis

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-27 08:52:19 -05:00
kennethreitz f4df5b88fe Fix JSON syntax errors in spirits and demons descriptions
Fixed two issues:
- Replaced unescaped straight double quotes with single quotes in "I wills"
- Fixed typo: "cunningbut" → "cunning but"

JSON now validates correctly.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 22:46:29 -05:00
kennethreitz 14bacc552a Expand spirits and demons page with multi-paragraph prose
Significantly expand 10 key theological sections with comprehensive,
multi-paragraph descriptions:

Major expansions:
- Demons Are Real: 4 paragraphs on reality of spiritual beings
- Origin of Demons: 4 paragraphs on fallen angels
- Demonic Hierarchy: 4 paragraphs on organized evil
- Names of Satan: 4 paragraphs on devil's titles and meanings
- Satan's Fall: 4 paragraphs on pride and rebellion
- Satan's Limitations: 4 paragraphs on defeated foe under God's sovereignty
- Binding the Strong Man: 4 paragraphs on plundering Satan's kingdom
- The Armor of God: 4 paragraphs on spiritual warfare equipment
- Demonic Deception: 4 paragraphs on wolves in sheep's clothing
- The Lake of Fire: 4 paragraphs on everlasting punishment

Each section now includes:
- Deeper theological exposition
- More biblical cross-references and connections
- Practical applications for believers
- Original language insights where relevant
- Historical and eschatological context

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 22:33:00 -05:00
kennethreitz 5a9fddd3e7 Remove 'Reformed' reference from Jeremiah book summary
Replace "Reformed understanding" with direct teaching statement:
- "This anticipates the Reformed understanding that even repentance is God's gift"
- → "This teaches that even repentance is God's gift"

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 21:43:45 -05:00
kennethreitz d77c45f7b7 Remove remaining 'Reformed' references from systematic theology resources
Replace 5 additional instances that used "Reformed tradition," "Reformed faith,"
and "Reformed worship":

- Bibliology introduction: "The Reformed tradition holds" → "Scripture is"
- Divine Existence: "The Reformed faith confesses" → direct statement
- Middle Knowledge Rejected: "The Reformed tradition rejects" → passive voice
- Regulative Principle: "The Reformed tradition holds" → direct statement
- Word and Sacrament: "Reformed worship" → "biblical worship"

Note: "reformed governments" on line 1563 uses "reformed" as a verb
(meaning "changed"), not as theological terminology, so it remains unchanged.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 21:40:53 -05:00
kennethreitz 0956c3776f Remove explicit 'Reformed theology' references from systematic theology resources
Replace all 12 instances of "Reformed theology" with alternative phrasing that
preserves the theological substance while removing the explicit label:

- Introduction sections: Use "Scripture teaches/emphasizes"
- Verbal Plenary Inspiration: "Historic Christian orthodoxy confesses"
- Scripture and Tradition: Remove attribution, state doctrine directly
- Compatibilism: "Scripture affirms"
- Cessation Question: State position directly
- No Sinless Perfection: "Scripture uniformly rejects"
- Simul Justus et Peccator: "This biblical truth"

Also includes previously staged template changes.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 21:39:31 -05:00
kennethreitz 64b63a5b8d Add systematic theology resources and update server routes
- Introduced new routes for systematic theology topics including Bibliology, Theology Proper, Anthropology, Hamartiology, Providence, Grace, Justification, Sanctification, Law and Gospel, and Worship.
- Each topic includes HTML and PDF endpoints for resource index and detail pages.
- Updated the resources page to include descriptions and counts for the new theology topics.
2025-11-26 21:08:50 -05:00
kennethreitz 621df3ae9d Remove duplicate chapter refs in Malachi outline 2025-11-26 17:14:30 -05:00
kennethreitz a27c0c639f Deepen Malachi introduction 2025-11-26 17:12:57 -05:00
kennethreitz 13a1bb2365 Expand data entries for key pastoral/minor prophet books 2025-11-26 17:10:32 -05:00
kennethreitz f6cb14ab71 Fix Hosea & Jonah data json formatting 2025-11-26 17:00:01 -05:00
kennethreitz f7d871607e Expand Haggai with comprehensive study content
Add extensive theological analysis, key themes, verses with significance,
and practical applications for in-depth Bible study.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 16:12:43 -05:00
kennethreitz 2fcc5932a3 updates to book summaries 2025-11-26 16:10:59 -05:00
kennethreitz 2483e57c98 updates to book summaries 2025-11-26 16:09:39 -05:00
kennethreitz 9388c8733c Fix markdown rendering in book Literary Style section
Apply markdown filter to Literary Style section to properly render
bold text and other markdown formatting. Makes it consistent with
other sections like Theological Significance.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 16:00:01 -05:00
kennethreitz d15d2309e8 Add 10 new Bible story collections and reorganize in chronological order
Add comprehensive story files for missing Bible narratives:
- Job's Suffering (7 stories)
- Samson's Strength (5 stories)
- Ruth & Redemption (4 stories)
- Samuel the Prophet (8 stories)
- Jonah & God's Mercy (4 stories)
- Daniel & Friends (6 stories)
- Esther & Deliverance (5 stories)
- Nehemiah Rebuilds (7 stories)
- Paul's Missions (5 stories)
- Revelation & Hope (10 stories)

Reorganize all story files in biblical chronological order:
- Old Testament stories: 01-15 (Creation through Nehemiah)
- New Testament stories: 16-23 (Jesus Birth through Revelation)
- Thematic collection: 24 (Heroes of Faith)

Each story includes comprehensive adult narratives (400-600 words) and
engaging kids narratives (200-400 words), with proper themes, verses,
and character lists. All content is theologically rich and biblically
faithful.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 15:41:10 -05:00
kennethreitz cd2f83d9c1 Expand Pentateuch book introductions with rich theological content
- Genesis, Exodus, Leviticus, Numbers, Deuteronomy fully expanded
- Each book now includes: multi-paragraph introductions, key themes with
  descriptions, key verses with significance, detailed outlines, historical
  context, literary style, theological significance, Christ in book,
  relationship to NT, and practical application
- Update book.html template to handle new data structure
- Add markdown filter for bold text conversion
- Template now supports both old and new data formats

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 14:41:35 -05:00
kennethreitz cf212062f7 Add individual book introduction JSON files for all 66 books
- Create books.py loader module with caching for book data
- Add JSON files for each book with introduction, themes, key verses,
  outline, historical context, literary style, Christ in book, and
  practical application sections
- Update API routes to include book metadata and introduction data
- Update book.html template to display rich book content
- Template falls back to commentary data when book_intro unavailable

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 14:26:11 -05:00
kennethreitz c03af4ed28 Convert interlinear data from gzipped Python to gzipped JSON
- Move interlinear_data.py.gz to data/interlinear.json.gz
- Simplify loader to read JSON directly (no more Python parsing)
- Reduced file size from 13.51 MB to 12.37 MB
- 31,031 verses of Hebrew/Greek interlinear data

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 10:47:16 -05:00
kennethreitz bef2da8129 Remove duplicate stories from new categories
- Removed Jonah and Daniel from Heroes of Faith (already in Prophets)
- Removed Still Small Voice from Elijah & Elisha (already in Kings)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 10:45:10 -05:00
kennethreitz 9cc0faf006 Remove duplicate Water into Wine story
Already exists in 08_jesus_ministry.json

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 10:43:01 -05:00
kennethreitz 01b6f9a9fa Add Miracles of Jesus and Elijah & Elisha story categories
New stories added:

Miracles of Jesus (8 stories):
- Water into Wine, Calms the Storm, Feeds 5000
- Walks on Water, Heals Blind Man, Raises Lazarus
- Heals Ten Lepers, Heals Paralyzed Man

Elijah & Elisha (7 stories):
- Elijah and the Ravens, Widow's Oil
- Mount Carmel, Still Small Voice, Taken to Heaven
- Elisha and Widow's Oil, Naaman Healed

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 10:41:27 -05:00
kennethreitz 105df4a18e Move embedded Python data to JSON files
- Move data from Python modules to JSON in data/ directory:
  - verse_collections.json, topics.json, biographies.json
  - cross_references.json, reading_plans.json, resources.json
- Update Python modules to load from JSON at import
- Remove intermediary Python data files from data/
- Move stories.py loader to main module directory
- Add Heroes of Faith Bible stories (Job, Ruth, Esther, Jonah, Daniel, Shadrach/Meshach/Abednego)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 10:30:31 -05:00
kennethreitz ffd9e8c187 Add PDF export for stories using WeasyPrint
- Add WeasyPrint dependency and system libs to Docker image
- Create PDF templates for adult and kids stories
- Add /stories/{slug}/pdf and /stories/{slug}/kids/pdf routes
- Add Download PDF button to story pages
- Add stories API endpoints: /api/stories and /api/stories/{slug}
- Gracefully handle missing WeasyPrint system libraries

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 00:26:25 -05:00
kennethreitz 608989347b Improve story text layout with Tufte-style typography
- Add newthought styling for first paragraph (small caps leading words)
- Add * * * divider between header/meta and narrative
- Add print styles for cleaner PDF output
- Applies to both adult and kids story templates

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 00:19:23 -05:00
kennethreitz 06be7a6d3c Add Jesus ministry stories (08_jesus_ministry.json)
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 00:11:18 -05:00
kennethreitz 7bd15f9698 Add kids stories index page at /stories/kids
- Playful colorful design matching individual kids story pages
- TOC grid with category links
- Search functionality
- Card-based grid with character badges and theme badges
- Links between adult and kids story indexes

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 00:10:19 -05:00
kennethreitz 2da1eb7846 Fix scripture links to use proper anchor syntax for verse ranges
Update story templates to link to chapter pages with #verse-X-Y anchors
instead of individual verse pages. This properly scrolls to and highlights
verse ranges like Judges 16:23-31.

Also adds more story JSON files (prophets, Jesus birth, parables, passion, acts).

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 00:07:18 -05:00
kennethreitz 23ce33e3b0 Add Bible Stories feature with adult and kids versions
- Add stories.py loader for JSON story files
- Add routes for /stories, /stories/{slug}, /stories/{slug}/kids
- Add templates: stories_index, story_detail, story_kids
- Include 32 stories across 4 categories (creation, patriarchs, exodus, conquest/judges)
- Add Bible Stories to homepage feature grid and explore links

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-25 23:53:03 -05:00
kennethreitz 65601d8b7f Add 11 systematic theology resources and simplify sidebar
New theological resources:
- The Trinity, Christology, Pneumatology, Soteriology
- Ecclesiology, Eschatology, Kingdom of God
- Types and Shadows, Messianic Prophecies
- The Blood in Scripture, Names and Titles of Christ

Updates:
- Add new resources to homepage Theological Studies grid
- Add Systematic Theology category to /resources page
- Simplify sidebar with single "All Resources" link
- Export new data variables from data/__init__.py

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-25 20:16:35 -05:00
kennethreitz 02ede39842 Expand Introduction to Spiritual Warfare section
Added 7 additional verses covering the full scope of spiritual warfare:
- Ephesians 6:13 (standing in the evil day)
- James 4:7 (resist the devil)
- Colossians 2:15 (Christ's triumph over powers)
- 1 John 4:4 (greater is He in you)
- Romans 8:37-39 (more than conquerors)
- Revelation 12:11 (overcoming by the blood)
- 2 Timothy 2:3-4 (good soldier of Christ)

Also enhanced description to emphasize Christ's victory at the cross.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-25 19:23:55 -05:00
kennethreitz 651bd1fd96 Expand biblical resource pages with additional content
- Add 7 missing Minor Prophets (Obadiah, Nahum, Habakkuk, Zephaniah,
  Haggai, Zechariah, Malachi) completing all 12
- Add 3 miracles: Second Catch of Fish, Syrophoenician Woman's
  Daughter, Healing the Multitudes
- Add 4 New Testament prayers: Philippians, Thief on Cross,
  Choosing Matthias
- Add 5 Psalms of Prayer: Psalms 63, 27, 86, 143

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-25 18:51:07 -05:00
kennethreitz e6a05c9697 test 2025-11-25 18:36:27 -05:00
kennethreitz 1e91f0b1f4 Add complete reading plans and center verse of the day
- Create comprehensive reading plans data file with complete daily readings:
  - One Year Plan (365 days with OT, NT, Psalms)
  - New Testament in 90 Days
  - Gospels and Acts in 30 Days
  - Psalms and Proverbs 31-day cycle
  - Paul's Epistles in 30 Days
  - Chronological plan (partial)

- Center verse of the day section on homepage with max-width constraint
- Add mobile responsive styling for verse of the day

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-24 20:24:02 -05:00
kennethreitz b974c1ff7f Extract biblical resources routes to separate module
- Create data/ package with centralized resource data (1,287 lines)
  - BIBLICAL_LOCATIONS, ANGELS_DATA, PROPHETS_DATA, NAMES_DATA
  - PARABLES_DATA, COVENANTS_DATA, APOSTLES_DATA, WOMEN_DATA
  - FESTIVALS_DATA, FRUITS_DATA

- Create routes/resources.py with thin route handlers (562 lines)
  - Maps, angels, prophets, names of God, parables
  - Covenants, apostles, women, festivals, fruits of spirit
  - Tetragrammaton special page

- Reduce server.py from 11,518 to 8,437 lines (~3,081 lines removed)
- Eliminate data duplication between list and detail routes
- All 100 tests pass

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-24 19:17:27 -05:00