According to most critics, the primary source for Shakespeare in the composing of As You Like It, is a novel Rosalyne: Euphues Golden Legacie by Thomas Lodge. As it was published in 1590, the timeline works, as does the fact that in the book’s introduction–entitled “To The Gentlemen Readers”–Lodge uses the phrase, “If you like it, so”… and some have made the logical leap to link this to the title of Shakespeare’s play.
Rosalyne: Euphues Golden Legacie, like As You Like It, is a pastoral romance, and has character analogs to many of the characters from our play, including Orlando (Rosader), Celia (Alinda), Oliver (Saladyne), Duke Senior (Gerismond), and–of course–Rosalind (Rosalyne).
In the above list, the melancholic Jaques is a notable absence. It has been proposed by some critics that he may be at least partially based on Marston’s The Malcontent, a play with a title character named Malevole. This is up for debate, though. Best guesses within Shakespeare scholarship is that As You Like It may have been written as early as 1599 and first produced around 1603. The Malcontent wasn’t published until 1604. And while this might seem to rule out Marston influencing Shakespeare, it is interesting to note that Marston’s play was first performed by Children of the Chapel, a group of boy actors that taken was over by the King’s Men, Shakespeare’s group. Could it be that the text of The Malcontent was part of that acquisition? Could be.
Regardless, the characters of Touchstone, Audrey, and William seem to be purely Shakespearean creations.