The filmographies of those two master film craftsmen, Stanley Kubrick and Steven Spielberg each include works touching on life in some distant time – “2001,” “Clockwork Orange,” “E.T.,” “Close Encounters of the Third Kind.” The original concept of “A.I.” was that of Kubrick, who worked over it for something like 20 years, discussing it with Spielberg largely via fax and phone. With Kubrick’s death in 1999, it seemed only fitting that Spielberg bring his friend’s project to the screen.

And what do we have? Two hours and 40 very slow minutes, roughly broken into three acts. Set in the seemingly not-too-distant future, we see the already disastrous effects of global warming. Highly evolved robots take care of the many tedious tasks of daily life. Procreation is severely controlled. To fulfill the desire of parents to have robotic children that can offer love like real children, Professor Hobby (William Hurt) has created the first of a new species programmed to love. Reason – science – replaces religion.

The parents chosen to benefit from this new kind of love have their own problems. The father works for the giant Cybertonics firm. He and his wife have a 10-year-old son with an incurable malady, sustained in a coma on life support. The parents from their first appearance are tense, nervous with one another, and very uncertain whether they really want this substitute son in their lives.

David – wondrously performed by a quite extraordinarily talented young actor Haley Joel Osment – also appears ill at ease, adjusting to his parents. He bursts out in raucous laughter on seeing spaghetti dangling from his mother’s lips at dinner. Soon though, the mother has decided to take the major step of child-parent bonding. We don’t hear the words exchanged, but David who has been calling her by her first name, “Monica,” responds to a question with “Yes, Mummy.” Mother love has been imprinted on this robot child.

But the real life son suddenly recovers and we have full-fledged sibling rivalry. To make matters worse, the live boy is a thoroughly nasty piece of work, always trying to get David into trouble, making mock of him until one prank carried too far makes it look as if David means to harm the other boy. The robotic Teddy Bear, once a toy of the live boy, chooses to stay with David, which only adds to the sibling rivalry. David has discovered the fairy tale of “Pinocchio,” taking it literally. If he can find the Blue Fairy, she will turn him into a real boy and his Mummy will love him as he loves her.” End of Act One, as Mother drives out into the woods with David who’s delighted to have his Mummy all to himself.

David, like an unwanted puppy, is being callously thrown away to be on his own. Act Two is much livelier with the arrival of Gigolo Joe (Jude Law), a “mecha” (for mechanical) programmed for love of a more earthy sort. With a deft click of his neck, Joe can burst into song, and with another shut himself off. Law and Osment, it must be said, are absolutely perfect. They bring charm, warmth, intelligence and genuine feeling to their performances. In short, two of the best performances on screen certainly this year and, frankly, much longer. Indeed when Joe vanishes from the film at the end of Act Two, so too does much of the interest in the film.

Act Two belongs to the mechas who are being rounded up for a thoroughly terrifying auto da fe, in which dozens are ripped apart, set afire, and destroyed, as crowds cheer. The scene owes much to “Mad Max Beyond Thunderdome.” Joe helps David in his quest for the Blue Fairy, taking him to Rouge City and introducing him to Doctor Know, a comic strip head suspended in space, which gives him cryptic directions that bring him to a Manhattan covered in water almost to the tops of its skyscrapers. This is where global warming is going to get us apparently, according to Mr. Spielberg.

Act Three, a quick 2,000-year leap forward in time. David and his teddy bear have been lying beneath the waves all those centuries waiting for David’s dream of the Blue Fairy to turn him into a real boy come true. And here we hit that old third-act problem: How to resolve our drama? Spielberg has recourse to those spindly, semi-transparent figures from “Encounters of the Third Kind.” Aliens from another planet? Another form of A.I. – artificial intelligence perhaps?

These “Third Kind” folk inform David that human kind is no more. Our world, as we know it is over, done with. They tell the boy he never will be human and, anyway, his mother can’t be brought back to life. But hold on, with a little DNA … Conveniently in Act One, David had clipped a lock of his mother’s hair, and the farsighted Teddy Bear had thoughtfully opened one of his seams and tucked the hair within, saving it for just such an occasion.

Think you’re in for a happy end? Sorry about that, say the “Third Kind” folk, but they’ve found people whose DNA has been preserved can only come back to life for a day, then just go to sleep forever more. David doesn’t care. He’s been waiting 2,000 years to get back with Mummy. What a wonderful day the two have. And how much Mummy loves her little boy. And how much he loves her. Oedipus gets to sleep for eternity with his beloved Mummy.

This is a PG rated movie. How will it play at the box office this summer season? Last time I looked, “Fast and Furious,” all about guys and fast cars was the number-one hit with moviegoers. Call me a cynic, but I think “A.I.” will have the biggest drop-off in its second week, since “Lara Croft: Tomb Raider” dropped 58 percent in its second week.

Note: Read our discussion guidelines before commenting.