(1):

(n.) A caprice; a freak; a fancy.

(2):

(n.) A piece in a free form, with frequent digressions from the theme; a fantasia; - often called caprice.