Warning: Any resemblance between the characters in "Dash and Lilly" and any real persons, living or dead, is purely coincidental. That said, this A&E drama based on the storm-tossed love affair of Dashiell Hammett and Lillian Hellman (tonight at 8) tries to be adult, smart and true to its period, and often succeeds.

Director Kathy Bates, who is better known as an actress, has succumbed to the appeal of the ever-popular tortured-artist myth. Under this concept, true artists are inevitably deeply flawed people, and their imperfections--drinking, cruelty, egotism, bad manners, etc.--can always be excused because their art enriches our own pathetically normal lives so brilliantly. We ought to have amassed enough evidence by now to know that this is claptrap, but the yearning to find redeeming greatness in rotten people lives on.

Thus Hellman--by many accounts mean, drunken, mendacious and promiscuous--is here a gutsy broad who wrote a couple of wonderful plays and a terrific letter to the House Un-American Activities Committee. And Hammett--a mean drunk, a philanderer, self-indulgent and emotionally barricaded--is with time's halo remembered for his ace detective stories and brave defiance of Red-hunting congressmen. He actually served six months in jail in addition to being blacklisted. She, this movie and her memoirs would have us believe, was reduced to serving as a salesgirl at Macy's.

Bates and screenwriter Jerry Ludwig have not ignored their warts, but they have put quite a bit of makeup on them. And truthfully, who would you rather spend a couple of television hours with--the nasty reality of these screwed-up people or the nobler (and prettier) duo in this production? I think we know the answer to that. Judy Davis, (Hellman) is far more photogenic than her real-life counterpart, who had what was then called an "interesting" face--centered by a bold nose--that aged into a much fiercer countenance. Sam Shepard, on the other hand, looks remarkably like pictures of Hammett, who had a white crew cut and a tall, lean frame. Both Hammett and Hellman had cigarettes permanently attached to their fingers and glasses of booze always at the ready.

People sure drank a lot in those days. They met in 1930, near the end of Prohibition, when she was 23 and he 36. Drinks were served 24 hours day, it seems, and there was a lot of strange behavior as a result.

To call these two dysfunctional is to be kind. To say they were neurotic is to ignore some deeply twisted aspects of their relationship. At one point, for example, Hellman goes to the airport to meet Hammett, who is arriving from Tijuana, where he went to obtain a Mexican divorce from his first wife--after what we are told is 10 years of being with Hellman. She sits at an outdoor cafe (they had nice airports in those days) sipping a drink and smoking, and then picks up a handsome salesman and goes off with him, just as the plane lands. She blithely turns up the next morning and refuses Hammett's proposal of marriage.

Hammett, for his part, vows his desperate need for her and then flirts outrageously with other women, and can only remain faithful for about five minutes when she leaves town. Their infidelities seem more like vengeful grudge matches than either erotic or romantic interludes.

Meanwhile, Hellman is becoming a famous playwright, and Hammett doesn't write much after "The Thin Man," which he finished when he was only 40. He enlists in the wartime Army at the age of 48 and is shipped off to some obscure duty on the Aleutian Islands. It seems more like a way for him to dry out and get away from her for a while than military service.

Their lives were certainly not without tumult. The money comes in, and it goes out, they move from hotel to apartment to hotel and finally buy a place in upstate New York. (In real life it was in Pleasantville, an interesting choice for them.) Then comes the McCarthy-Nixon era, they lose everything, the IRS hounds them. He tries to stop drinking; she tries; both keep smoking. She complains to her friend Dorothy Parker (saucily played by Bebe Neuwirth) that she and Dash never have sex anymore. And then he gets lung cancer.

There is one moving scene toward the end, when Hellman tries to celebrate their 30th anniversary. He is dying but doesn't know it. All she asks for is that he say he loves her and cannot live without her, but he won't say it. So she writes a letter meant to be from him to her, which expresses all she has meant to him. As Shepard reads the letter aloud, choking back tears, you get a sense of their deep mutual need, and that perhaps each brought out the best in the other as well as the worst. After he dies, she fights for him to be buried in Arlington National Cemetery--a moment of redemption for a hard, hard woman.

The supporting players--a portly Laurence Luckinbill as Hellman's Washington lawyer, Joseph Rauh, and Neuwirth--compliment the excellent Shepard and Davis well. And all the period details, down to the slight sepia tone of the film, create a context in which we can view these disturbed folks without wondering why someone isn't calling the men in white coats.

CAPTION: Judy Davis and Sam Shepard as dysfunctional lovers Lillian Hellman and Dashiell Hammett.