def create_position_ids_from_inputs_embeds(self, inputs_embeds):
        """
        We are provided embeddings directly. We cannot infer which are padded so just generate sequential position ids.

        Args:
            inputs_embeds: tf.Tensor

        Returns: tf.Tensor
        """
        input_shape = shape_list(inputs_embeds)[:-1]
        sequence_length = input_shape[1]

        position_ids = tf.range(
            start=self.padding_idx + 1, limit=sequence_length + self.padding_idx + 1, dtype=tf.int64
        )
        return tf.broadcast_to(tf.expand_dims(position_ids, 0), input_shape)

        We are provided embeddings directly. We cannot infer which are padded so just generate sequential position ids.

        Args:
            inputs_embeds: tf.Tensor

        Returns: tf.Tensor
        
dpkd/transformers/src/transformers/models/esm/modeling_tf_esm.py