Most of the work on temporal representation issues in Machine Learning deals with the problem of learning/mining temporal patterns from a large set of temporal data. In this paper we investigate the somewhat different problem of learning the behavioral rules of a system from its observed temporal properties formalized in temporal logic. Our interest in this problem arose from Systems Biology and the development of machine learning techniques for learning biochemical reaction rules and kinetic parameters in the Biochemical Abstract Machine BIOCHAM. Our contribution is twofold. First, in the general setting of Kripke structures and concurrent transition systems, we define positive and negative CTL formulae and propose a theory revision algorithm for learning transition rules from a CTL specification. Second, in the setting of hybrid systems which add a continuous dynamics described by differential equations, we show how a similar algorithm can be built to learn parameter values from a constraint LTL specification. In the context of BIOCHAM, which is used as a running example in this paper, we report evaluation results showing the usefulness of this approach and encouraging performance figures.