This paper presents a theory and a computational implementation for ge
nerating prosodically appropriate synthetic speech in response to data
base queries. Proper distinctions of contrast and emphasis are express
ed in an intonation contour that is synthesized by rule under the cont
rol of a grammar, a discourse model and a knowledge base. The theory i
s based on Combinatory Categorial Grammar, a formalism which easily in
tegrates the notions of syntactic constituency, semantics, prosodic ph
rasing and information structure. Results from our current implementat
ion demonstrate the system's ability to generate a variety of intonati
onal possibilities for a given sentence depending on the discourse con
text.