Al Perry wears a haunted look. He doesn't smile easily.He knows he chucked it out the window - the job he loved and held for nine years: Trainer and keeper of the elephants at the National Zoo.

In the last year, Perry has seen an elephant only a few times. He looks after zebras and gazelles these days. He is sorry, bitter, hurt and contrite. He hopes virtually around the clock for another chance with the animals he adores.

But he isn't going to get it, "not as long as I'm here," says Theodore Reed, the zoo director. The reason is that, one day in April 1977 Al Perry did exactly what a professional elephant trainer is not supposed to do.

He blew his cool.

Perry was in a cage with Shanthi, the zoo's prized three-year-old elephant from Sri Lanka, the beast who had been given to Amy Carter on behalf of America's children.

Perry wanted Shanthi to eat a meal. As elephants will, Shanthi had other ideas. So, for reasons Perry cannot fully explain even 14 months later, he flew into a rage and broke a glass bottle full of Shanthi's watery rice across the elephant's head.

The only casualty was Perry. He spent two weeks in a hospital recovering from deep gashes in his right hand. When he returned to work, he was assigned to other large mammals, and told he would never again work with his floppy-eared friends. Shortly afterward, the position of elephant keeper and trainer was formally abolished by zoo officials. Elephants are not tended on a rotating basis.

No keeper, could have been closer to his animals than Perry was to the National Zoo's three elephant - Shanthi, Ambika and Nancy. In fact, Perry is the first to admit he grew too close.

Were the elephants moody? Perry would sleep beside them in their cages all night, on his own time. Were they getting too little attention? Perry would don a bathing suit and wash with them. Were they sick? Perry would nurse them with a dedication that bordered on the fanatic.

But when the elephants were balky, Perry admits he sometimes could not handle them - or himself. It tended to become a test of wills. "I have a temper, oh, yes," says Perry. "And occasionally, when they weren't doing what I said, I lost it."

In 1970, he lost it in public, and beat one elephant several times with an elephant hook - a long stick with a prong on the end of it. A tourist was taking home movies at the time, and later turned the film over to the Washington Humane Society. Society officials protested, and Perry was ordered to undergo psychiatric evaluation. He did, and he was restored to his position.

In 1973, a similar incident took place, again involving an elephant hook. Perry was suspended for 30 days, but was again allowed to return. After the 1977 incident, Reed and other zoo officials ran out of patience.

Perry's transfer has nearly crushed him. "They (the elephants) meant so much to me. The job meant so much to me," said Perry, a short, slim 55-year-old with a flowing red beard. "It's been humiliating. They (zoo officials) know what it's done to me. They know how bitter and resentful and full of hate I am. My morale is shot."

In one way, zoo officials disagree. Perry, who has spent 16 years on the zoo staff, "has been doing a good job for the last year (or since his transfer)," said zoo director Reed. "And in a way, i have protected him. I can name three or four zoos he would have been fired from in half an hour."

But "Al simply could not control himself," said Reed. "I thought Al was salvagable, and apparently he wasn't . . . Al wanted it set up so he was th eonly one who had contact with the elephants. That's a prima donna problem, and we can't have prima donnas. I have all the sympathy in the world for Al, but I'm just not going to trust a man who can't control himself."

Christine Stevens, a former board member of the Washington Humane Society and the woman who spearheaded the 1970 grievance against Perry, is even stronger in her criticism. "He should be completely removed from contact with animals," she said.

To meet Al Perry, or to see him in action with animals most of the time, would make one wonder if Reed and Stevens weren't talking about a different person.

Shy and softspoken, a gentle bachelor of simple tastes, a nonsmoker who square dances and jogs a mile a day, Perry grew up around animals near Bristol, Va. He has spent much of his adult life with them, first as a caretaker for the National Institutes of Health, later with the zoo.

But around the zoo, Perry has sometimes seemed to be an odd man out.

For example, just after being appointed elephant keeper in 1968, he was sent to St. Louis for training. He insisted on staying with relatives, and refused to accept the government's per diem.

In 1976, Reed and other zoo officials decided to sell Dzimbo, an aging and sometimes troublesome elephant, to an amusement park in Florida. Because he vehemently disagreed with the decision, Perry refused to accept a $100 fee zoo officials offered him for his part in preparing Dzimbo for shipment.

Perry says he has thought about quitting, "but people are not eager to hire 55-year-olds." Besides, his $18,000 a-year salary is far above what another zoo or a circus would pay him. "And I'm established in Washington," Perry said.

But perhaps the strongest reason for staying is that, whenever it's not too painful for him, Perry can sneak a visit with his old friends.

"Oh, yes, I've done it a couple of times," he said. "And they know me. One day - the regular man that day was sick - they asked me to bathe the baby and give her her hay. She ignored the hay and took her trunk and started to smell me.

"That was when I broke up and had to leave."

Al Perry acknowledges that "I'm not blameless, I'm not guiltless. I just don't think I deserve what I've gotten. To think I'll never, never work with them again is hard to take."