Researchers have developed a robot that can "coactively learn" from humans and quickly adjust their behavior during tasks as they work at a pretend grocery store checkout counter.

"We give the robot a lot of flexibility in learning," Ashutosh Saxena, assistant professor of computer science, said in a Cornell University news release. "The robot can learn from corrective human feedback in order to plan its actions that are suitable to the environment and the objects present."

Robots working on modern-day assembly lines can only repeat actions; they cannot adjust their movements based on surrounding conditions and stimuli.

The researchers used the example of a robot that would know to be gentler with tomatoes than canned goods, and could move a knife around while keeping it a safe distance away from nearby humans.

The robot has two arms that bend both at the "wrist" and "elbow." Since the robot's arms were so flexible it was difficult for people to know how to direct the limbs movement; to remedy this the researchers created a touchscreen "face" that would exhibit three trajectory options the customers could choose from.

The touchscreen allows the robot to plan its own trajectory, but also allows the human participant to "fine-tune" its movement by manually moving its arms.

"The robot has what the researchers call a 'zero-G' mode, where the robot's arms hold their position against gravity but allow the operator to move them," the news release reported. "The first correction may not be the best one, but it may be slightly better. The learning algorithm the researchers provided allows the robot to learn incrementally, refining its trajectory a little more each time the human operator makes adjustments or selects a trajectory on the touch screen. Even with weak but incrementally correct feedback from the user, the robot arrives at an optimal movement."

As humans interact with the robot, it learns to associate different motions and trajectories with certain objects. The robot learns things such as to keep fragile eggs near the counter's surface, and not to swing a knife near a human customer.

Most people that tested the robot were able to train it to apply appropriate movements to the object in question with five corrections, the robot was then able to use that knowledge in different environments.

WATCH: