But if you want a different product category, how about kitchen knives. If you use one to murder a person, the device is functioning properly but we wouldn't hold the manufacturer liable.
I don't think it's a problem. We can use the same standard we use already in other areas, the reasonable person standard. If a reasonable person would (or should) assume that harm would result from the way they used the software then the user is on the hook. If a reasonable person would not assume that harm would result from the way they used the software then the company would be on the hook.
With that framing we don't have to debate the technical points of if the software was "functioning properly", and instead can just focus on the specific use and what the expected result of that use would be. The subjectivity of the reasonable person standard is a strength. It grows along with us. What a reasonable person would know or expect today when AI is fairly new will not be the same as what they should know or expect after the technology has been used everywhere for the last 80 years.