The boss cow saunters to the head of the line and, with a flick of her hip, cuts off two other ladies. She's itching to get at the tasty brown morsels waiting in the feed trough.

"It's like candy for them," Lisa Groetsch said as she oversaw milking on her Stearns County farm one recent afternoon. "It's full of protein and nutrients."

Groetsch and her Holstein herd represent the leading edge in a new wave of farm technology that is sweeping into the Upper Midwest: a dairy robot so sophisticated that it has practically taken the milker out of milking. The robots -- which not only milk the cows but also control their feed and adjust their schedules -- have spread to about 50 dairy farms in Minnesota and Wisconsin since they were first installed in 2006. The Dutch manufacturer, Lely, recently expanded its North American headquarters in Iowa to include a 36,000-square-foot production facility, the company's first outside the Netherlands.

Now, Groetsch says, the robots have the potential to save Minnesota's dwindling community of family dairy farms.

Many dairy kids leave the farm because they see their parents slave away in milking parlors twice a day, seven days a week, with never a vacation or even a break for the children's baseball games. With robots, a mechanical arm handles the milking and each cow chooses its own routine, leaving farmers with more time for family and flexibility for other chores.

"Younger kids like technology. ... [Robots] are keeping the new generation on the farm," said Marcia Endres, a University of Minnesota Extension dairy scientist.

By reducing labor costs and increasing productivity, robots can also help small family farms compete with big dairy operations springing up in California and other states.

But the machines don't come cheap. Each can cost between $150,000 and $200,000 -- a significant investment for small farmers, considering that the price of milk has fallen about 20 percent in the last year.

24-hour operation

After researching the technology for five years, Groetsch and her family got a loan and bought four milking robots in January. They hope to repay the money in 10 years.

Groestsch says the gamble was worth it. The family's small squadron of farm droids, which includes a mechanical cow-back scratcher and an automatic feed pusher, has turned their barn into a 24-hour operation, with less hired help.

The 3,000-pound, red robo-milkers work around the clock, except for twice-daily cleaning sessions. They also eliminate the chore of corralling cows for milking: After being trained to accept the robot, cows get milked whenever they please. The robot measures their production and knows if a cow needs to be milked more or less often.

The robots may also reduce the farmer's risk of getting kicked, pinned or tail-whacked, said Dr. Matthew Keifer, director of Marshfield Clinic's National Farm Medicine Center in Wisconsin. Many dairy farm injuries occur when the herd is being moved for milking; he and colleagues at the University of Minnesota are studying how technology might be changing injury patterns in the dairy industry.

The robots also could reduce back, knee, shoulder and other repetitive-motion injuries associated with wrangling a dairy herd, Keifer said.

Doug Heintz, a dairy farmer near Caledonia, said the injury issue influenced his decision to buy two milking robots in 2008. "I didn't know how long my body could hold up," he said. "I decided to save my body the rest of the wear and tear."

Since she switched to robots, Groetsch says, her shoulders hurt less, but she and her husband have put on weight.

"It's like the freshman 15," she joked.

Spared some of the physical labor, Groetsch and her family spend more time looking over robot-driven data, including cow body temperature, teat health and milk quality. Such precision farming can help farmers detect health problems in their herds early.

Flashing lasers

When a cow walks into the robot stall, the machinery identifies her by an electronic neck tag, records her weight and parcels out food pellets. It washes each of her four teats with two rotating brushes. Then, with flashing red laser beams, it finds her teats and attaches red-and-white suction cups. The intelligent machine remembers each cow's teat placement, so it can start milking faster each time.

If a cow is not ready to be milked again, the robot withholds the treat, opens the door and sends the cow on her way.

The robot knows when a cow has broken a milk hose, when its cleaning solution has run low, and when it hasn't seen a particular cow in a while. But its self-awareness has limits: For some problems, it phones the farmer.

The Groetsches still have to ensure that the machines are cleaning up after themselves, that bullies in the herd aren't blocking access to the robot, and that bovine health is not compromised. They still rely on a nutritionist and a veterinarian, and they redesigned their barn to make it more comfortable for the cows.

"This system works best if you think about re-creating your whole approach," said Janice Siegford, a Michigan State University professor who studies robotic milking.

Now, researchers say, milking technology might turn the tables and help reinvent the cow. Robots have difficulty finding teats on hairy udders or teats with unusual spacing. As a result, farmers might breed cows for perfect teat placement; cows that can't learn the robot system might not make the cut. Some farmers might even advertise their cows as robot-ready when they go to market.

Of course, strategic breeding is nothing new. Dairy farmers have consistently chosen high-producing cows. Along with improvements in nutrition, farm management and machinery, genetic selection has produced a roughly three-fold increase in milk production per cow since the early 1950s.

Groetsch thinks she and her family will choose robot-friendly cows as breeders in the future, but for now they're still adjusting to life on a robotic farm.

So far, one of their biggest victories has been convincing her 89-year-old father-in-law, who milked cows during the Depression, that the technology works. He sat for hours watching the robot. Finally he said, "You know? It gets better every day."

Daniela Hernandez • 612-673-4088