code: def create(cls, mr_spec, shard_number, shard_attempt, _writer_state=None):
      
      writer_spec = cls.get_params(mr_spec.mapper, allow_old=False)
      seg_index = None
      if writer_spec.get(cls._NO_DUPLICATE, False):
        seg_index = 0
  
      # Determine parameters
      key = cls._generate_filename(writer_spec, mr_spec.name,
                                   mr_spec.mapreduce_id,
                                   shard_number, shard_attempt,
                                   seg_index)
      return cls._create(writer_spec, key)
docs: Inherit docs.