Organic compounds known as terpenes are produced by most plants as a defense against herbivores, who otherwise would consume them, and as semiochemicals that serve to communicate chemically with other living things. There are over 120 different types of terpenes that can be expressed by the cannabis plant, although some are only found in trace amounts. Read more here.