DEV Community

Cover image for GhostWeb AI — Resurrecting the Lost Web
Aditya Mote
Aditya Mote

Posted on

GhostWeb AI — Resurrecting the Lost Web

This is a submission for the Hacktoberfest Open-Source AI Challenge Week 4: Ghost in the Machine

Every website dies eventually. Some of them just don't know it yet.

What I Built

Think of the first website you ever loved: a fan page, a forum, a weird little homepage with a visitor counter. Now try visiting it. Most likely it's gone, redesigned, or buried under something new.

But it didn't vanish completely. Somewhere in the Internet Archive, a ghost remains. So I built a tool to go looking for it.

GhostWeb AI is a digital archaeology tool. It combines the Internet Archive's Wayback Machine with a local, open-weight AI model to dig through dead web pages and ask what they have to say.

I took "Ghost in the Machine" literally, twice:

  • 👻 The ghosts are the traces of websites that once existed.
  • 🤖 The machine is the AI that helps us explore those traces.

What it can do

Feature What happens
🔎 Find snapshots Search the Wayback Machine for historical versions of any site
🕵️ Analyze the evidence Extract page text and get a local AI analysis grounded in that material
👻 Generate ghost stories Turn archived content into an eerie, fictional tale
💾 Save artifacts Keep analyses and stories locally for later
🖥️ Retro terminal UI Digital archaeology should feel like a haunted terminal

⚠️ Important distinction: The archive provides the history. The ghost stories are AI-generated fiction. They're creative interpretations, not evidence of anything supernatural, and not proof of what a site's creators intended.

Demo

GhostWeb AI runs as a Flask app on your own machine. Once dependencies are installed and the Ollama model is available, start it and open:

http://127.0.0.1:5000
Enter fullscreen mode Exit fullscreen mode

There's no live hosted demo because everything runs through local inference with Ollama. Here's the full workflow instead:

Archive Search

Archive Analysis

Ghost Story

Code

GitHub logo Rx-Metallica / GHOSTWEB_AI

A local-AI digital archaeology toolkit for exploring forgotten websites using the Wayback Machine and Ollama.

Repo path: GhostWeb-AI. It has the source code, templates, styling, dependencies, and docs.

The core idea: web preservation + local AI, instead of yet another chatbot that answers generic prompts.

How I Built It

Stack: Python · Flask · Wayback Machine · Ollama · Gemma 3 4B

The séance, step by step

 🌐 Enter a URL
      │
      ▼
 🔎 Search for archived snapshots
      │
      ▼
 📜 Retrieve archived page content
      │
      ▼
 🧠 Local Gemma model analyzes it / writes a story
      │
      ▼
 💾 Display the result + save as a local artifact
Enter fullscreen mode Exit fullscreen mode

Under the hood

  • Python + Flask: application logic and web routes
  • Wayback Machine: snapshot discovery and access to archived pages
  • Ollama: runs the model locally
  • Gemma 3 4B (gemma3:4b): analysis and fictional storytelling
  • HTML + CSS: the terminal-inspired retro interface
  • Markdown rendering + sanitization: model output shows up as clean, formatted content, with the rendered HTML sanitized

🐌 The hard parts

Speed vs. quality. Running a language model on consumer hardware isn't always fast. Instead of sending huge requests, I kept prompts and responses focused.

Making AI output readable. Raw Markdown symbols in the browser look like a curse. I made sure headings, lists, and emphasis render properly.

🚀 Run it yourself

You'll need Python, Ollama, and the gemma3:4b model.

# 1. Pull the model
ollama pull gemma3:4b

# 2. Install dependencies
python -m pip install -r requirements.txt
Enter fullscreen mode Exit fullscreen mode

Then start the Flask app using the project's configured entry point and visit http://127.0.0.1:5000.

Response speed depends on your hardware and available memory.

Why Does Open Innovation Matter?

This project would have been a very different thing if it depended on a closed AI API.

With an open-weight model through Ollama, I can:

  • ✅ Run inference on my own machine
  • ✅ Experiment freely with prompts and generation settings
  • ✅ Build around the model without sending archived page text to a hosted AI service

That freedom matters for digital archaeology. The source material can be old, incomplete, strange, or just plain interesting, and I want control over how it gets interpreted.

It also makes the project easy to extend. Other developers could:

  • 🧪 Try different local models
  • 🔧 Improve the text extraction
  • 🗂️ Add richer archive metadata
  • 🎨 Invent new ways to explore historical pages

The Internet Archive makes history accessible. Open-weight AI makes it explorable. Together, web history becomes something you can investigate and interact with.

The Spirit of It

An archived website is more than a screenshot. It's a fragment of a lost digital world: a homepage, a pile of links, a design trend, a service that may no longer exist.

GhostWeb AI starts with that fragment and asks two questions:

1. What can we learn from what remains? (analysis)

2. What fictional story could this digital ruin inspire? (imagination)

I'm not pretending the past can be perfectly reconstructed. I just want forgotten corners of the internet to feel worth exploring again.

The archive preserves the evidence. The AI adds a fictional voice. The developer decides how to bring them together.

Prize Categories

Best Use of Gemma: gemma3:4b

GhostWeb AI is built around Gemma 3 4B running locally through Ollama. It powers both halves of the app: grounded analysis of archived page text, and creative ghost-story generation. A small model that fits on consumer hardware keeps the whole tool private, offline-friendly, and easy for anyone to run.


Built for **Hacktoberfest Open-Source AI Challenge Week 4: Ghost in the Machine.

👻 Explore the past. Analyze the traces. Let the machine tell a story.

Top comments (2)

Collapse
 
ranjit_kmable_fadaf5f0731 profile image
Ranjit Kmable •

The best work you do the greatest gratitude you recieve so keep going on

Collapse
 
ranjit_kmable_fadaf5f0731 profile image
Ranjit Kmable •

Great to review this great work