The wikipaedia discord server bot
Find a file
2026-07-03 02:22:24 +02:00
cogs debug 2026-07-03 02:22:24 +02:00
.gitignore debug 2026-07-03 02:21:17 +02:00
LICENSE.md license changes 2026-05-18 23:36:24 +02:00
main.py forgej 2026-06-27 20:29:23 +02:00
README.md forgej 2026-06-27 20:29:23 +02:00
requirements.txt wiki-fetch requirements fix 2026-06-29 08:57:03 +02:00
restarting.txt fixing my fuckup 2026-06-27 20:48:55 +02:00
tools.py fix source cited even when there's no source url, improvements on reference context 2026-05-20 01:37:13 +02:00
util_ansi.py wiki-fetch 2026-06-29 08:49:28 +02:00

Configuration

the config json looks like this

{
  "BOT_TOKEN": "discordbottokenhere",
  "TOGETHER_API_KEY": "togetherapikeyhere",
  "TOGETHER_MODEL": "meta-llama/Llama-3.3-70B-Instruct-Turbo",
  "FORGEJO_WEBHOOK_CHANNEL_ID": 123456789012345678,
  "FORGEJO_WEBHOOK_SECRET": "insertyosecrethere",
  "FORGEJO_WEBHOOK_HOST": "0.0.0.0",
  "FORGEJO_WEBHOOK_PORT": 8080,
  "FORGEJO_WEBHOOK_PATH": "/forgejo/webhook"
}

Installlation

if ur using conda:

conda create -n wikipe python
conda activate wikipe
pip install -r requirements.txt

if venv:

python3 -m venv .venv
. .venv/bin/activate
pip install -r requirements.txt

and to run the bot:

python main.py

Permissions

give the bot message-content intent enabled

Bridging

Forgejo webhook crap:

  • Set FORGEJO_WEBHOOK_CHANNEL_ID in config.json
  • Add a Forgejo webhook in the repository settings
  • Use webhook type Forgejo, method POST, and content type application/json
  • Set the target URL to your public bot URL plus FORGEJO_WEBHOOK_PATH, for example https://example.com/forgejo/webhook
  • Put the same secret in Forgejo and FORGEJO_WEBHOOK_SECRET
  • Enable push, branch, and tag events