1. A method of conducting directed evolution of one or more polypeptide or polynucleotide molecules, the method comprising, (a) receiving sequence data of a plurality of polypeptide molecules or a plurality of polynucleotide molecules encoding the plurality of polypeptide molecules, wherein the sequence data comprises identities and positions of a plurality of amino acids for each molecule of the plurality of polypeptide molecules or a plurality of nucleotides for each molecule of the plurality of polynucleotide molecules; (b) receiving activity data of the plurality of polypeptide molecules; (c) fitting a sequence-activity model to the received sequence data and the received activity data, wherein the sequence-activity model receives as one or more inputs one or more amino acids of a polypeptide molecule or one or more nucleotides of a polynucleotide molecule encoding the polypeptide molecule, the sequence-activity model provides as an output an activity of the polypeptide molecule, the sequence-activity model has a form comprising a product of a plurality of terms, and each of two or more of the plurality of terms comprises an independent variable representing at least one amino acid or at least one nucleotide at a sequence position and a coefficient representing a contribution to the activity by the at least one amino acid or the at least one nucleotide at the sequence position; (d) determining one or more amino acid sequences or one or more nucleic acid sequences using the sequence-activity model; (e) synthesizing one or more amino acid molecules or one or more nucleic acid molecules based on the one or more amino acid sequences or one or more nucleic acid sequences; and (f) recombining or performing mutagenesis on the one or more amino acid molecules or one or more nucleic acid molecules to provide the one or more polypeptide or polynucleotide molecules.