Install brightd by entering the following commands in the terminal:
sudo apt update sudo apt install brightd
daemon which regulates brightness of LCDs dynamically
The idea is taken from the way Macs behave: If a user is inactive for a certain time, it automatically darkens the screen. It is designed for IBM/Lenovo Thinkpads, but works with every display which is controllable via /sys/class/backlight/.