When applying machine learning techniques to more complicated datasets, it is often beneficial to use ensembles of simpler models instead of a single, more complicated, model. However, the creation of ensembles is a tedious task which requires a lot of human interaction and experimentation. In this paper, we present a technique for construction of ensembles based on typed genetic programming. The technique describes an ensemble as a directed acyclic graph, which is internally represented as a tree evolved by the genetic programming. The approach is evaluated in a series of experiments on various datasets and compared to the performance of simple models tuned by grid search, as well as to ensembles generated in a systematic manner.