WTH can't we have a battery fail prediction for devices?

AppDaemon does quite a good job for alerting at a battery threshold for devices.
I also have a nice card for displaying device batteries
But I would like is failure prediction.

Status extract from my dashboard:

          - type: horizontal-stack
            cards:
              - type: custom:battery-state-card
                name: Batteries
                sort_by_level: asc
                collapse: 6
                tap_action: more-info
                filter:
                  include:
                    - name: attributes.device_class
                      operator: '='
                      value: battery
                  exclude:
                    - name: entity_id
                      operator: matches
                      value: /.*_battery_islow$/

It is not a simple thing to predict.
Modern batteries are developed to maintain a high voltage output for as long as possible and then die suddenly, but the death point vary a bit from vendor to vendor and model to model.
Other factors as age of the batteries, the load being pulled by the devices and even the temperature affects it too.
If it is a rechargeable battery, then the number of recharges will affect it too.
The point of death can be off by quite alot when measuring the voltage due to this factors.
If your device then only draws a little over a timespan then you might be off by days, week, if not months.

So what is a good battery prediction?
One that warns you, so you have time to switch batteries withput the device dying in the meantime, but with the change you really does not use the batteries that we’ll.
Or one that use the battery well, but then sometimes it just dies without ever getting to the point where it sends the warning?

I guess OP means to not use some magic, but to analyze the previous run times. Like HA sees that the battery hasnt been replaced for 3 weeks, then the device died, then the device is suddenly reachable again with 100% battery. You can store the run time in a database and calculate the average run time until the battery dies. But this approach requires that the device already has a battery sensor set up or you do some hackery to tell HA that the device has a battery and when it isnt reachable anymore, the battery is dead and you save again the run time.

The same factor will apply and your average will not be very precise or predictable.
In fact it will be worse without the voltage sensor.