Some scientists see viruses as blueprint packets ancient bacteria created to mail out in multiple copies -- highly efficient DNA distribution at a distance. Smaller packets of tradable DNA are called plasmids.
Lewis Thomas, former head of Yale Medical School, better known for his wonderful science essays, suggested that ancient bacteria may have invented us as big taxis to get around in safely (Lives of a Cell, Bantam, NY 1975). I think it more likely we are conference centers for their information exchange. After all, we continually breathe in and absorb bacteria, viruses, plasmids and other loose snippets of DNA, permitting them to throng about in our guts, cells and even in our chromosomes.
Scientists express surprise at how much "biological activity" goes on in our genomes, and at bacteria living in them. They now see that over forty times as much DNA as that in known genes is devoted to TEs -- transposable elements known since Barbara McClintock's pioneering work half a century ago, showing that TEs not only move about but do so in response to stress on the organism. Her results have been supported by many later researchers, including Eshel ben Jacob, who sees the genomes of bacterial colonies as group minds able to respond intelligently to stress on their colonies (Sahtouris, A Walk Through Time, Wiley, NY, 1998).
It seems reasonable to suppose that our genomic system, too, is behaving intelligently as a constant hive of activity now known to edit and repair itself. If it did not know what it was doing, I believe it would revert to chaos in very short order.