How can one turn off "Insights" e-mails?

How can one turn off "Insights" e-mails?

by Edward Hewlett -
Number of replies: 25

We have a number of teachers in our Moodle who have Manager privileges who do not want to receive the "Insights" e-mail that automatically gets sent out. I have searched the settings and cannot seem to find a setting that would allow me to turn off these e-mails... nor is it clear to me which permission to turn off if I want to create a Manager role which does not receive the analytics "Insights" e-mail.

Any assistance anyone can offer in pointing me towards a solution to this problem would be much appreciated!

Average of ratings: -
In reply to Edward Hewlett

Re: How can one turn off "Insights" e-mails?

by David Monllaó -

Hi Edward,

You can turn off insights notifications in User menu > Preferences > Notification preferences

Average of ratings: Useful (3)
In reply to David Monllaó

Re: How can one turn off "Insights" e-mails?

by Edward Hewlett -

Thank you, David. That's helpful.

Anyone able to point me to the associated permission the e-mail is based on? I'm wanting to make a Sub-Manager role that will automatically not get these e-mails.

In reply to Edward Hewlett

Re: How can one turn off "Insights" e-mails?

by Randy Thornton -

Edward,

It seems to check the capability 'tool/inspire:listinsights' when sending messages. This is set to Allow for the default Teacher, non-editing teacher and Manager roles. 

So leave it unset for that custom role should be enough to stop the messages. If a person has multiple conflicting roles, you may have to set it to Prevent or even Prohibit, but just unsetting it should be enough for a single system level role.

Randy


Average of ratings: Useful (1)
In reply to Edward Hewlett

Re: How can one turn off "Insights" e-mails?

by Peter Jonker -

Turning off the report completely seems to be done through /admin/tool/analytics/index.php where you can use the Actions dropdown to disable the report.

Average of ratings: Useful (3)
In reply to Peter Jonker

Re: How can one turn off "Insights" e-mails?

by Mathew Gancarz -
Picture of Core developers
It might make sense to consider the permissions structure for this. We just updated to 3.5 and had a nice surprise when a whole bunch of people received the "No teachers" insight email as they had Manager level access. We turned off that insight for now and I definitely do not want to ask each manager to turn off the email notification in their own settings.
In reply to Mathew Gancarz

Re: How can one turn off "Insights" e-mails?

by Elizabeth Dalton -

I agree that this functionality requires more thought. Right now we have one capability that can be assigned -- or blocked-- per context. Anyone with that capability in a context will get all insights for that context.

What would be a better way of handling the recipients of insights? In general, I am hoping we can make the generation and tracking of insights more sophisticated. See MDL-62523 for the current proposal.

In reply to Edward Hewlett

Re: How can one turn off "Insights" e-mails?

by Richard van Iwaarden -

I'm puzzled by this.

I'm a site-admin with all messaging enabled. I never ever got a mail about insights.

This summer we upgrade to 3.5 and suddenly I have people complaining that they receive these 'insight' Emails.

My questions now are:

  1. Why does the main site-admin not get these reports?
  2. Why do other people get these reports (I think if they are manager at some category level they already start getting mails)
  3. How do I turn off all Emails except for myself?

Hope anyone can help with this.
Average of ratings: Useful (1)
In reply to Richard van Iwaarden

Re: How can one turn off "Insights" e-mails?

by David Monllaó -

Hi Richard,

Replying to your questions below:

  1. By default, predictive models that report insights at system or category level only notify users with 'moodle/analytics:listinsights' capability. This is a bug, I've just created an issue to fix it: MDL-64315. The fix will be backported to stable versions.
  2. They have 'moodle/analytics:listinsights' at system context. At least this is what I deducted after testing it myself in my dev box.
  3. You can't do it right now without editing the source code. This would require an extension of the insights reporting APIs as Elizabeth mentioned before.
In reply to David Monllaó

Re: How can one turn off "Insights" e-mails?

by Elliott Benzle -

We also upgraded and had a lot of teachers thinking this was spam or a fishing email. Since the 'insights' wasn't very useful for us I turned it off. This might be overkill, but here are all the steps I took.


- Edited file /analytics/classes/local/target/base.php commented out line 214 that sent the email

- Set permissions for all roles to 'prohibit' for 'moodle/analytics:listinsights'

- To turn off for a specific user: go to user profile > Preferences > Notification preferences > turn off insights

- Turned off scheduled tasks: Admin Settings > Server > Scheduled Tasks > disabled both 'Predict Models' and ' Train Models'

- Disable under: Admin Settings > Analytics > Analytic Models > Actions > Disable (for both)


Another issue was the email was set to come from the Site admin, so it had my name instead of the normal 'Noreply' like other emails. That caused additional confusion. After doing the above we aren't getting those emails anymore.



Average of ratings: Useful (4)
In reply to Elliott Benzle

Re: How can one turn off "Insights" e-mails?

by David Monllaó -

Thanks for your comment Elliott. Note that just disabling the models should be enough. The scheduled tasks only run for enabled models.

Re "Insights are generated from an admin account, they should be using the noreply account", I've just created MDL-65085 to fix it. Thanks for reporting it.

Average of ratings: Useful (2)
In reply to Richard van Iwaarden

Re: How can one turn off "Insights" e-mails?

by David Monllaó -
Hi Richard,

There have been some recent changes on how this work and more changes are coming for 3.8.

- Regarding the emails sender: In https://tracker.moodle.org/browse/MDL-65085 we started sending the insights from the noreply account, but we got some negative reports about it as it seems that people didn't clearly see that the email was coming from a moodle site. We are changing this again now in MDL-66090 so emails will be sent from the support user account like we do in other components (some other components use noreply though).
- Regarding the admin not receiving emails: In MDL-64315 we evaluated the possibility of sending insights to the admin as well. We finally discarded this option.

You can find more info in the linked issues, including the pros and cons of each option and an explanation of the final decision.
In reply to David Monllaó

Re: How can one turn off "Insights" e-mails?

by Richard van Iwaarden -
Thanks for the update!

As for admins not getting the mails: I understand that you don't want admins to get ALL these mails... but... since I'm not a teacher I will never get these mails. Yet teachers will be asking me questions about these mails (that I can not see).

It has to to with what kind of Moodle admin you are probably. Some just focus on the technical (keep Moodle running) others try te be an adviser for teachers (like myself) on how to set up courses, which activities to use, etc.

Now the teachers will receive 'Insight' mails and I would like to see how 'insightful' they really are. I would like to advise them to use this information or ignore it.

Can every teacher make the decision themselves to receive or not to receive these mails per course? Can they make a decision to get the mail from course A and not from course B?

I'm just puzzled by this... as it is a feature where I as an admin have little control over.
In reply to Richard van Iwaarden

Re: How can one turn off "Insights" e-mails?

by David Monllaó -

Hi Richard,

First of all, thanks for your feedback. Please note that as an admin you have full access to all the insights reports generated for the teachers, just that you don't get a notification about all of them. You can find all the information related to analytics models and insights in admin/tool/analytics/index.php. Also, if you really want to get the notifications as teachers do you just need to follow these steps: https://docs.moodle.org/37/en/Analytics_settings#Defining_roles.

Teachers not get the mail from course A and not from course B, at the moment they can only subscribe or unsubscribe from all the insights. This is something we want to improve in the future: MDL-66573. The insights report though, is always available under Course admin > Reports though, even if the insights notifications are disabled.

In reply to David Monllaó

Re: How can one turn off "Insights" e-mails?

by Richard van Iwaarden -

Hi David,

When I (as admin) go to /report/insights/insights.php?contextid=1 I get the message 'no insights reported'.

Any idea how to turn this on then?

If I look at my scheduled task log (3.7) then this always fails:

Predict models

\tool_analytics\task\predict_models

Unfortunately, the log errors give no information other then a very long list:

Execute scheduled task: Predict models (tool_analytics\task\predict_models)
... started 16:40:02. Current memory use 4.8MB.
Analysing id "4" with "Upcoming week" time splitting method...
Analysing id "5" with "Upcoming week" time splitting method...
etc.
Average of ratings: Useful (1)
In reply to Richard van Iwaarden

Re: How can one turn off "Insights" e-mails?

by David Monllaó -
Hi Richard,

Re. /report/insights/insights.php?contextid=1, contextid = 1 is the system context, the only model working at that context level is 'No teaching' (it is likely to be renamed to 'Courses at risk of not starting' in 3.8). This model reports on courses with no teachers or no student enrolments that are starting during the next week. The most likely explanation for not getting insights at that context level is that the model is disabled, another reasonable explanation is that there are no courses matching these conditions in your site. If you want to test this model you can create a new courses with start date tomorrow and with no teachers or no students. Go to site admin > analytics > analytics models and execute Get predictions (or Execute scheduled analysis in 3.8dev). You should see the course you just created in /report/insights/insights.php?contextid=1. If you want to get notifications about these insight check your notification preferences page, insights should be "on".

Re. \tool_analytics\task\predict_models always failing, I can't see the error in the attached snippet. Could you paste it?
In reply to David Monllaó

Re: How can one turn off "Insights" e-mails?

by Richard van Iwaarden -

I can't find 'get predictions'... where to find it?



In reply to Richard van Iwaarden

Re: How can one turn off "Insights" e-mails?

by David Monllaó -
Hi Richard,

You need to disable the 'onlycli' setting (you have some info the in notification) 'Get predictions' (or 'Execute scheduled analysis', depending on the version) will appear under the Actions menu.
In reply to David Monllaó

Re: How can one turn off "Insights" e-mails?

by Michele Ferris -
I really like this feature for my teachers of online courses. But some of the courses are independent studies and they teachers don't want insights for those courses. Is there a way to turn insights on/off for each course or only per user (in notification preferences)?

Thanks,
Michele
3.8.5+
Average of ratings: Useful (1)
In reply to Richard van Iwaarden

Re: How can one turn off "Insights" e-mails?

by Kai Niethammer -
Hi all,

I am in a very similar situation.

I am a site admin who acts as a consultant to the teachers and course managers.
I would like to activate analytics to be able to evaluate the feature and verify the outcomes/use them for my consultancy.
At the same time I do not want the system to send the mails to teachers and managers in the first step. This might be a future scenario.

Reading through this thread it seems to me there is still no option to turn of the mailing while keeping analytics alive, am I right?
In reply to Kai Niethammer

Re: How can one turn off "Insights" e-mails?

by Elizabeth Dalton -

Hi,

We have directions on how to set up a limited pilot in the Learning Analytics Working Group. In short, you have two main options:

  1. Remove the default "viewinsights" capability from the Teacher role and set up a new role, e.g. "Analytics Pilot Teacher" that only has this capability, and give this role to teachers who want to participate in the pilot
  2. Limit a model to specific contexts (Moodle 3.8+)
You may wish to support one or more of the following tracker issues:

  • MDL-59058 Make insights notifications optional
  • MDL-66573 Allow users to opt-out of specific insights
Best regards,

Elizabeth
Average of ratings: Useful (2)
In reply to Elizabeth Dalton

Re: How can one turn off "Insights" e-mails?

by Matthew Davidson -
Picture of Core developers Picture of Plugin developers

We are running 3.7 and I would love to run analytic models without notifying the teachers.  

I am not seeing a "moodle/analytics:listinsights" capability.  Is this the capability that determines if a teacher gets an insight notification?

thank you for listing the 2 trackers.  I will follow both of them.

Average of ratings: Useful (1)
In reply to Elizabeth Dalton

Re: How can one turn off "Insights" e-mails?

by Marc Couture -
Thank you for linking to those two trackers, we just updated to Moodle 3.8 and received a flurry of emails from users concerned about being spammed.
In reply to Marc Couture

Re: How can one turn off "Insights" e-mails?

by shpetim aliaj -
HI Guys,

The same here, how can we fix this one as the teachers got flooded. we just upgraded to 3.9.2 so i think its a issue on 3.9.2 too.

Tim