I do similar with Home Assistant to virtually eliminate clipping. Luxpower inverters have a mode called 'Charge Last' which switches the priority, after house load, to export rather than charge the batteries. In that mode only the solar generation over the inverter AC capacity goes to the batteries. Basically the batteries are only charged by the small amount of power above the inverter limit, the area of the diagram that is clipped once the batteries reach 100%.
Of course you wouldn't want to leave the inverter in this mode so it's only something you would use when you can automate it, which is where Home Assistant comes in. I use PV predictions for the day, Solcast and ForcastSolar, to determine the level of grid charge of the batteries overnight. During the day an automation determines when Charge Last is required, based on PV predicted remaining for the day, whilst still ensuring the battery SOC rises high enough to provide power in the evening until the cheap overnight starts.
It required a lot of tinkering over the first year, is not perfect, and the financial benefits are dubious with cheap EV tariffs, but it satisfies my mild OCD to maximize solar yield