Links to Churches
How to Use the Interactive Map
The Bible Verse Similarity Map is a visual representation of connections throughout the entire King James Bible. Each pixel on the map represents a comparison between two verses. The darker the pixel, the more similar the verses are in their meaning.
- Navigating the Map: You can explore the map by using your mouse to click and drag, panning across the map.
- Zooming In and Out: To get a closer look at specific areas of interest or to see the bigger picture, use the scroll wheel on your mouse or the + and - controls on the map to zoom in and out. As you zoom in, you will see more detailed relationships between smaller sets of verses.
- Discovering Verse Connections: The core feature of this tool is the ability to see the specific verses behind each pixel. Click on any point on the map to reveal the two verses being compared. Their text will be displayed, allowing you to read and compare them directly.
How the Map was Made
This interactive map is the result of transforming the biblical text into a visual format. Here’s a explanation of the steps involved:
- Understanding the Verses: First, every single verse in the King James Bible was fed into a computer model that is trained to understand the meaning of sentences. This model, called a sentence-embedding model, converts each verse into a unique set of numbers, known as a vector. This numerical representation captures the verse's essence.
- Comparing Every Verse: With each verse represented by numbers, they can be mathematically compared. A similarity score was calculated for every possible pair of verses in the Bible, resulting in a dataset that quantifies the relationships between them.
- Visualizing the Similarities: These similarity scores were then used to generate a grid of image tiles. Each pixel in these tiles corresponds to a unique pair of verses, and its color is determined by how similar those two verses are. The darker the pixel, the higher the similarity score.
- Creating the Interactive Experience: These image tiles are served to you through an interactive map interface, built with Leaflet.js. This technology allows you to fluidly zoom and pan across the 1 million verse comparisons, making the exploration of these biblical connections both intuitive and engaging.
The entire project is powered by a combination of modern web technologies. A FastAPI backend handles the data, while the user-friendly front end is built with HTML, CSS, and JavaScript. The complex data processing and storage are managed by tools like Polars, ChromaDB, and NumPy, with the final image tiles being generated using Pillow and served in a map using Leaflet.