Offset for light sensor

Hi, I have a motion sensor with a light sensor (Athom) next to a light under a kitchen cabinet. Sadly there is no other place for the sensor. The light is dimmable and has tunable white.

I want to add an (negative) offset to the measured light value to approximate the real light level.

Normally I would darken the room and measure the light level at different light settings to create a table and interpolate values between.

But how can I do this in Home Assistant?

With a Template Sensor.