Blue Jasmine is certainly one of the most arresting of Woody Allen’s late-career escape-from-New-York movies. It has the shape of a comedy, and it’s often very funny; but as the story proceeds, we come to realize that its protagonist, the titular Jasmine, is someone we can’t bear to keep laughing at. Lurching through the film in a haze of delusion and desperation, barely maintaining on a diet of Xanax and vodka, Jasmine is one of Allen’s most harrowing characters; and in bringing her to life on the screen, Cate Blanchett gives a performance that pivots from frazzled to doom-ridden and back with a virtuoso’s ease.

The story is a retooling of Tennessee Williams’ A Streetcar Named Desire. Blanchett’s Jasmine is a self-coddling New York society matron whose life of hermetic luxury – the vast Park Avenue apartment, the beachfront Hamptons estate, the pressing question of whether or not to buy a private jet – has been provided by her husband, a Wall Street investment hustler named Hal (played by Alec Baldwin, a master of all things slick and sketchy). When Hal is busted for fraud and sent to prison, the IRS swoops in to confiscate his every asset, leaving Jasmine, a woman with no discernible skill sets, unmoored.

Sort of homeless, she flees to San Francisco to impose upon the blue-collar hospitality of her cheery sister, Ginger (Sally Hawkins, entirely lovable). This relationship feels forced. Jasmin and Ginger have no blood connection – they were separately adopted by their parents – but that doesn’t entirely explain how they turned out to be such polar-opposite individuals: Ginger, a lowly grocery-store clerk, is all heart, while Jasmine, for whom the concept of work is mostly a rumor, is all id and very little else.

Jasmine’s decision to seek shelter with her sister is an especially impudent move. It was Jasmine who had encouraged Ginger’s husband, Augie (an affecting Andrew Dice Clay), to invest their family nest egg in one of Hal’s shady business deals; after the money vanished, Ginger’s marriage collapsed. But Ginger nevertheless welcomes Jasmine into the cluttered apartment she shares with her two kids and, quite frequently, the boyfriend she hopes to marry, a good-natured prole named Chili (Broadway star Bobby Canavale).

As the story advances, Allen uses frequent flashbacks to Jasmine’s New York life to illuminate her fish-out-of-water floundering in San Francisco. The social instruction he seeks to impart is a shopworn cliché: the glittery rich can be immoral monsters, while the working class, with their simple beer-centered pleasures, are the salt of the earth. Still, his witty script mines steady laughter from Jasmine’s incessant bumblings. Uncertain whether to become an anthropologist or an interior decorator, she takes a job as a receptionist with an amorous dentist (Michael Stuhlbarg in a too-small role), then hooks up with a more promising meal ticket, a monumentally smarmy young diplomat named Dwight (Peter Sarsgaard). Can Jasmine’s wreck of a life be salvaged? Will Woody Allen allow it?

Although the cast is a dream assemblage (not least Louis C.K. as jovial sound engineer putting the moves on Ginger), Blanchett is all the reason anyone might need to see this movie. Giving voice to Jasmine’s internal chaos in extended arias of jibbering delusion, she’s a wonder to behold. But the picture is fatally undermined by the icy detachment with which Allen observes her pained incomprehension. Because Jasmine isn’t just a spoiled bitch getting a comical comeuppance; she’s a real victim, apparently of a bipolar disorder. (She has already done time in a sanitarium, and weathered electro-convulsive therapy to no avail.) If this were a real comedy – which in the end it’s decidedly not – we could enjoy her learning of long-delayed life lessons. But it’s not reality therapy that Jasmine needs, it’s professional help, which might not be enough in any case. Allen the writer extends her no helping hand, and our laughter dribbles away. The movie’s devastating final scene chills us to the bone.