An unmanned robot has been used to stitch together a pig's bowel, moving science a step closer to automated surgery, say experts.
Unlike existing machines, the Star robot is self-controlled - it doesn't need to be guided by a surgeon's hands.
In tests on pigs, it at least matched trained doctors at mending cut bowel, Science Translational Medicine reports.
But it is very early days and it remains to be seen if people would trust such a "hands-off" approach.
Robots performing surgery are not new. Hospitals in the UK and the US already use robot assistants to help cut out hard-to-reach tumours, such as prostate cancer.
These devices, such as the da Vinci System, are an extension of the surgeon - gadgets that give the operator better sight of the target and more adept tools to get the job done.
But scientists are now trying create a new generation of robots that will work independently, albeit under close supervision, to remove human error.
In theory, the medical team could sit back and watch the machine perform, and only get involved if necessary.
Robots are best suited for repetitive, predictable work. Getting them to stitch soft tissue that slips and slides around in the body when it is manipulated is a challenge.
Dr Peter Kim and colleagues at the Children's National Medical Center, in Washington, say they have found a way to get round this with their Smart Tissue Autonomous Robot or Star.
Fancy sewing machine
Star "reads" fluorescent markers in the soft tissue to know precisely where to plant its stitches on the moving target.
Like a regular sewing machine, it can be programmed for things like stitch size, pattern and tension.
And it appears to perform slightly better than skilled humans in terms of stitch positioning to repair a cut in a pig's intestine.
Dr Kim said: "If you want to throw in 20 stitches, it is not enough that a human being does 19 out of 20 well. You have to do all 20 of them well to have a good outcome.
"This machine will consistently throw in 20 perfect sutures."
That is not to say the robot is infallible.
In the trial, carried out on live animals in the operating theatre and on tissue samples in the lab, the scientists had to supervise the robot and tweak what it was doing around 40% of the time.
Dr Kim said: "These are minor adjustments, very much like when you see your little baby starting to walk. We were a little nervous about it to make sure it does it the right way.
"It can be fully autonomous for the task we want to do."
He hopes robots like this could reduce surgical errors, improve outcomes and save lives.
Mr Shafi Ahmed, from the Royal College of Surgeons of England, said it was a radical step to try to replace a surgeon with a machine, but not necessarily a bad one in certain situations.
"All humans make errors. We have emotions and we get tired, whereas robots are objective.
"We need to ask whether machines might be better at doing some parts of surgery.
"Obviously there are issues around the ethics and trust. At what point do you trust a robot? This study suggests autonomous robots can do quite complex processes competently."
Dr Kim says the technology could be used on patients within the next couple of years. And one day, it may be possible to carry out routine operations, such as gall bladder or appendix removals, from start to finish using robots.
Follow Michelle on Twitter