A prominent aspect of the notion of musical similarity across the music of various cultures is related to the local matching of melodic motifs. This holds for Indian art music, a highly structured form with raga playing a critical role in the melodic organization. Apart from the tonal material, a raga is characterized by a set of melodic phrases that serve as important points of reference in a music performance. Musicians acquire in their training a knowledge of the melodic phrase shapes or motifs particular to a raga and the proficiency to render these correctly in performance. This phenomenon of learned schema might be expected to influence the musicians' perception of variations of the melodic motif in terms of pitch contour shape. Motivated by the parallels between the musical structure and prosodic structure in speech, identification and discrimination experiments are presented, which explore the differences between trained musicians' (TMs) and non-musicians' perception of ecologically valid synthesized variants of a raga-characteristic motif, presented both in and out of context. It is found that trained musicians are relatively insensitive to acoustic differences associated with note duration in the vicinity of a prototypical phrase shape while also clearly demonstrating the heightened sensitivity associated with categorical perception in the context of the boundary between ragas.