Well you just need to know and understand; chord tones, passing tones, chromatic notes, modes, rhythm, phrasing, articulation, stylistic nuances, all the notes on the fingerboard and transcribe a whole load of melodies (not necessarily played on bass).