-
Bug
-
Resolution: Fixed
-
Minor
-
5.0
-
MOODLE_500_STABLE
-
MOODLE_500_STABLE
-
MDL-85106-main -
-
-
-
1
-
Team Hedgehogs 2025 Sprint 1.4
As noticed by marycooch and investigated by stronk7, the AI usage report doesn't show any tokens for Explain text actions.
From Eloy:
There must be some bug there, in explain action. I've tried here with both OpenAI and Ollama providers an get the same.
I did quick debug and see that, internally, both the prompt and the completion tokens are being counted ok and stored in the database ok for the explain action, but for some reason they don't show in the report.
I'd bet that the report needs some update to get the info from the explain action.
Yeah, it's the report. I just fixed it here. It's missing support for explain text.
Attached is Eloy's patch to get the explain text counters working.