Is Jesus speaking from Himself or is the Holy Spirit speaking through Him? When Jesus spoke, are the words recorded His own as the Messiah, or those of God delivered through Him by his Holy Spirit? How can we distinguish?

Jesus and the Holy Spirit who filled Him sometimes operated independently. When the woman who had bleeding for twelve years touched Jesus’ cloak and was healed (Luke 8:44-47) Jesus said, ‘Who touched me?’ and, ‘Someone touched me; I know that power has gone out from me.’ 

A distinction also seems implicit in Luke 12:10: ‘Everyone who speaks a word against the Son of Man will be forgiven, but anyone who blasphemes against the Holy Spirit will not be forgiven.’

And for us, then and now: ‘At that time you will be given what to say, for it will not be you speaking, but the Spirit of your Father speaking through you.’ (Matthew 10:19-20)

So how do we interpret such as Jesus saying ‘before Abraham was born, I am!’? (John 8:58). Is Jesus saying He is God, or is God saying I am God through his Holy Spirit?
Jesus spoke for the Father.

John 12:49 says, 


  "For I did not speak on My own initiative, but the Father Himself who sent Me has given Me a commandment as to what to say and what to speak."


John 14:10 says, 


  "Do you not believe that I am in the Father, and the Father is in Me? The words that I say to you I do not speak on My own initiative, but the Father abiding in Me does His works."


So the words that Jesus spoke were the Father's words. Now, how he came to know and speak those words is that the Spirit of the Father rested upon him. The words that he spoke are the Fathers words, and he only spoke the words that the Father bade him speak, and did the things that the Father bade him do.