File size: 1,957 Bytes
adb8008 4ef16fc adb8008 4ef16fc adb8008 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | ---
title: Scripture Knowledge Graph
emoji: ✨
colorFrom: blue
colorTo: purple
sdk: gradio
sdk_version: "6.20.0"
app_file: app.py
pinned: true
license: mit
short_description: Bible notes to an AI knowledge graph with swarm intelligence
---
# Scripture Knowledge Graph
Transform your Bible study notes into an interactive knowledge graph powered by graph theory, swarm intelligence, and AI theological analysis.
## Features
- **NLP entity extraction** — automatically identifies people, places, themes, theological concepts, books, verses, time periods, and events, plus directed relationships ("Paul wrote to Timothy")
- **Interactive D3 force graph** — drag, zoom, click to explore; hexagon/diamond/star/triangle node shapes by entity type; neon glow rendering
- **Graph algorithms (NetworkX)** — PageRank, greedy-modularity communities, betweenness/degree/eigenvector centrality, clustering coefficient, diameter, density, bridges, articulation points
- **ACO Swarm Intelligence** — a real Ant Colony System (Dorigo & Gambardella, 1997) traces the dominant conceptual pathway through your notes, with a live convergence readout
- **AI Insights** — Claude streams a theological + graph-structural analysis of your notes, grounded in the computed topology and swarm results
## How to use
1. Paste your Bible study notes (or click **Sample**)
2. Click **Build Knowledge Graph**
3. Explore — click nodes, try layout modes, drag, zoom
4. Click **Run Swarm Analysis** to let ants find the dominant pathway
5. Open the **AI Insights** tab and click **Generate Insights**
## Setup
This Space calls the Anthropic API server-side. Add your key as a **Space Secret** named `ANTHROPIC_API_KEY` (Settings → Variables and secrets). It is never exposed to the browser.
## Technical stack
Graph algorithms: NetworkX · Visualization: D3.js v7 · AI: Claude (Anthropic, server-side streaming) · Swarm: Ant Colony System (Dorigo & Gambardella, 1997)
|