This Adagio is a keyboard arrangement realized by Johann Sebastian Bach or by his son Wilhelm Friedemann from the original for violin. It is interesting to take a look to the violin version in order to realize how Bach’s transcription is an ingenious and thorough rewriting of the violin piece.
I have uploaded the score of the violin version of the Adagio