In our competitive society, some consider it a badge of honor to get only four or five hours of sleep a night, or pull all-nighters in the service of work.

And forget naps. But sleep may have more benefits than just making you sharper and more alert during your waking hours. Sleep also brings dreams, and these, according to new research, can give shape to creative ideas that come to us like gifts from a muse.

While you sleep, your brain isn’t idle. It’s still working for you — and now scientists have found ways to direct dreams and squeeze more creative juice from them.