This repository was archived by the owner on Mar 31, 2026. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 32
Expand file tree
/
Copy pathconfig.example.py
More file actions
86 lines (86 loc) · 4.31 KB
/
Copy pathconfig.example.py
File metadata and controls
86 lines (86 loc) · 4.31 KB
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# COPY THIS FILE INTO A FILE CALLED config.py AND CHANGE THE VALUES AS NEEDED.
# discord API bot token https://discord.com/developers/applications
bot_token = "EXAMPLE_TOKEN"
# BotBlock tokens. see https://pypi.org/project/discordlists.py/
bot_list_data = None
# bot_list_data = {
# "examplebotlist.com": {
# "token": "exampletoken"
# },
# }
# number of commands that can be processed at once. set to None to automatically use OS cpu core count.
# set to -1 to remove limit.
workers = None
# manually specify tempdir rather than using OS's default
override_temp_dir = None
# NOTICE is recommended, INFO prints more information about what bot is doing, WARNING only prints errors.
log_level = "NOTICE"
# amount of seconds cooldown per user commands have. set to 0 to disable cooldown
cooldown = 3
# minimum height/width that media will be sized up to if below
min_size = 100
# maximum height/width that media will be downsized to if above
max_size = 2000
# maximum size, in bytes, to download. see https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Length
max_file_size = 25_000_000
# maximum file size, in bytes, that a file can be. if resulting file is bigger than this, mediaforge instantly gives
# up and does not try to upload nor resize the file.
way_too_big_size = 100_000_000
# the text to use for different messages, can be custom emojis or just any text
emojis = {
"x": "<:xmark:803792052932444180>",
"warning": "<:wmark:803791399782580284>",
"question": "<:qmark:803791399615070249>",
"exclamation_question": "<:eqmark:803791399501168641>",
"2exclamation": "<:eemark:803791399710883871>",
"working": "<a:working:803801825605320754>",
"clock": "<:clockmark:803803703169515541>",
"one": "<:one:826643438555758622>",
"two": "<:two:826643438421671987>",
"three": "<:three:826643438723923968>",
"resize": "<:resize:826643438354694165>",
"check": "<:check:826643438652489778>"
}
# up to 25 tips that can show when using $help tips. type \n for a newline
tips = {
"Media Searching": "MediaForge automatically searches for any media in a channel. Reply to a message with the "
"command to search that message first.",
"File Formats": "MediaForge supports static image formats like PNG, animated image formats like GIF, and video "
"formats like MP4.",
"Self-Hosting": "MediaForge is completely open source and anyone can host a clone "
"themself!\nhttps://github.com/machineonamission/mediaforge "
}
# configured upload limit, in bytes, for files.
# MediaForge has no mechanism beyond this to check file upload limit, so ensure you know what you're doing before changing it.
file_upload_limit = 10 * 1024**2 # 10 MiB, default upload limit
# configured emoji size upload limit, in bytes
emoji_upload_limit = 256 * 1024 # 256 KiB, seems to be the default emoji limit?
# configured sticker size upload limit, in bytes
sticker_upload_limit = 512 * 1024 # 512 KiB, sticker limit
# this applies to every command. if any string arguments contain any of these words, the command will instantly
# fail. this is intended to block hateful language like slurs. not case sensitive.
# its in the config so i dont have to upload slurs to github...
blocked_words = []
# filename of the sqlite3 database. currently only used for storing server-specific prefixes.
db_filename = "database.db"
# default prefix for commands
default_command_prefix = "$"
# this url will be sent a periodic request. this is designed to be used with an uptime monitoring service
heartbeaturl = None
# how often (in seconds) to request the heartbeat url
heartbeatfrequency = 60
# number of shards
# set to None or remove and "the library will use the Bot Gateway endpoint call to figure out how many shards to use."
shard_count = None
# maximum number of frames an input video can have, will be trimmed if it's too long
max_frames = 1024
# maximum temp file size from FFmpeg. reduce if ffmpeg eats into your disk/memory too much, increase if youre able
max_temp_file_size = "1G"
# cap FPS for sanity
max_fps = 100
# intermediate codecs that files are saved to between ffmpeg calls, i wouldn't touch these but depending on cpu/ssd
# speed, you might get better results with different ones
temp_vcodec = "utvideo"
temp_vpixfmt = "rgba"
temp_acodec = "pcm_s16le"
temp_vipscodec = "tiff"