Configuration
Configuration
Configuring Moodle Mate is essential to tailor the application to your specific needs. Below is a detailed guide on how to set up your config.ini file.
Configuration File Structure
The config.ini file contains several sections and keys that you need to configure. Here’s a breakdown of each section and its purpose:
Moodle Configuration
This section contains the credentials and URL for your Moodle instance.
[moodle]moodleUrl = YOUR_MOODLE_URLusername = YOUR_USERNAMEpassword = YOUR_PASSWORDOpenAI Configuration
If you are using OpenAI’s services for summarization, provide your API key here.
openaikey = YOUR_OPENAI_API_KEYPushbullet Configuration
Configure Pushbullet if you want to receive notifications on your devices.
pushbulletkey = YOUR_PUSHBULLET_API_KEYpushbulletState = 1 # Set to 1 to enable, 0 to disableDiscord Webhook Configuration
For sending notifications directly to a Discord channel through webhooks.
webhookState = 1 # Set to 1 to enable, 0 to disablewebhookUrl = YOUR_DISCORD_WEBHOOK_URLSystem Message Configuration
Customize the message that the llm uses to summarize incoming messages.
systemmessage = "Your custom system message here"Example: systemmessage = "You are an assistant. Your task is to succinctly summarize incoming messages."
Model Configuration
Specify the model used for generating summaries or responses.
model = gpt-4o # or any other model you preferAdditional Settings
Here you can configure other aspects like whether to use fakeopen API or not, and the bot’s name.
fakeopen = 0 # 0 to disable (recommended, as it`s currently not maintained)summary = 1 # Set to 1 to enable summarization, 0 to disablebotname = MoodleMate # Display name for the bot on DiscordthumbnailURL = YOUR_THUMBNAIL_URL # URL for the bot's thumbnail imageExample Configuration
Here is an example of how your config.ini might look:
[moodle]moodleUrl = https://example.moodle.comusername = exampleUserpassword = examplePass
[api]openaikey = exampleKeypushbulletkey = examplePKeypushbulletState = 1webhookState = 1webhookUrl = https://discord.com/api/webhooks/exampleWebhooksystemmessage = "You are an assistant. Your task is to succinctly summarize incoming messages."model = gpt-4ofakeopen = 0summary = 1botname = MoodleMatethumbnailURL = https://example.com/image.pngTips for Configuration
- Security: Keep your
config.inifile secure, especially if it contains sensitive information like passwords or API keys. - Updates: Check for updates in the Moodle Mate documentation to see if new configuration options are available.
This configuration guide should help you set up Moodle Mate to work efficiently within your environment.