A difference is the output of software development can be immediately applied in an automatic way - production leads to delivery as a matter of fact. The whole flow can actually be automated.
Producing legal documents on the other hand is only part of the process, a lawyer or similar must still apply the produced text in some human driven context.