Jeyadev R

Local LLM · Ollama · Discord bot

A local-first AI content pipeline for a Discord community

FRONTIER: Ollama, Gemma 3 and human approval, with no cloud API calls

By Jeyadev R · 2026-10-19

The problem

The Discord server for our student tech community was missing good content, because manually discovering, filtering, writing and publishing it every day does not scale. I built FRONTIER to do that work, with one rule: nothing leaves my machine and nothing goes live without approval.

What the pipeline does

  • Discovers hackathons, research papers and AI news automatically from 10+ sources.
  • Scores relevance with a local LLM (Ollama running Gemma 3 4B).
  • Drafts posts in the community voice, following the server style guide.
  • Lets a human approve or reject each draft in a React dashboard or with Discord buttons before anything is published.
  • Publishes to the right Discord channel on a schedule and keeps a full audit trail in SQLite.

Why local-first

The LLM inference, the writing-style profile and the community configuration all stay on the machine. There are no GPT API calls, so there is no per-request cost and no community data sent to a third party. A small local model is enough here because the tasks are narrow: score a link for relevance, then rewrite it in a known style.

Human in the loop

An automated bot posting unreviewed AI text into a community is a risk, so FRONTIER only drafts. The approval step, available in the dashboard or as Discord buttons, is the part that makes it safe to run daily. The stack is Python and FastAPI on the back end with a React dashboard.

How it is built

  • A FastAPI back end with a REST API and interactive docs.
  • A local LLM layer that works with both Ollama and LM Studio.
  • A Discord bot with slash commands and inline approve, reject and regenerate buttons.
  • A React dashboard with a Generate, Preview, Approve, Publish flow.
  • SQLite tracking every post through its full lifecycle.
  • A style examples folder: drop in your own writing and the model follows its tone.
  • An MCP server built with FastMCP, so AI coding agents can call FRONTIER tools directly.

Routing posts to the right channel

FRONTIER routes each draft to one of 10 channels by topic: #neural for AI and machine learning, #forge for projects and code, #lab for research papers, #arena for hackathons, #bug-hunt for debugging help, #missions for challenges, #launchpad for student showcases, #signal for announcements, #frontier-guide for tutorials and #frontier-lounge for general chat.

Running it on a Windows PC

FRONTIER is designed to start with Windows: it installs as a background service or runs from the system tray. On boot it waits for the local LLM, discovers content, drafts posts and queues them for approval. Setup is a PowerShell script plus a .env file with the Discord bot token, server ID and Ollama model name.

Questions people ask

Can a Discord bot use a local LLM instead of the OpenAI API?

Yes. FRONTIER runs its model through Ollama or LM Studio on the same machine, so there are no API costs and no community data leaves the PC.

Does FRONTIER post automatically?

No. It only drafts. Every post needs human approval in the React dashboard or with Discord buttons before it is published.

Which model does it use?

Gemma 3 4B through Ollama for scoring and drafting. The model name is a setting, so other Ollama models work too.

How does it match the community writing style?

You add example posts to a style examples folder, and the model uses them as a guide for tone when drafting.

Discussed on LinkedIn

Overleaf and GitHub session for students at FRONTIER

More from the blog