A two-armed robot in a Chiba factory carefully stacks rice balls in a box, which a worker carries off for shipment to convenience stores. At another food-packaging plant, a robot shakes pepper and powdered cheese over pasta that a person has just arranged in a container.

In a country known for bringing large-scale industrial robots to the factory floor, such relatively dainty machines have until recently been dismissed as niche and low-margin.

But as the workforce ages in Japan and elsewhere, collaborative robots — or "cobots" — are seen as a key way to help keep all types of assembly lines moving without replacing humans.