mpd:
- manifest_edit.plugins.mpd.label_remove:
    # This config file makes use of the "label_remove" plugin to remove
    # "Label" and a "GroupLabel" elements from a manifest.
    #
    # "label_remove" allows to specify the position where the label
    # will be removed with reference to a specific Representation or
    # Adaptation Set, inside one or more Period if necessary. This reflects
    # the general structure of a DASH manifest, which is briefly recapped
    # here to better clarify how to configure the plugin.
    #
    # Tracks in mpd manifests are specified as list of Representations
    # inside a given Adaptation Set, inside a given Period. The general
    # scheme can roughly be illustrated as
    #
    # Manifest:
    #  |- Period id:
    #     id = "id"
    #     |- AdaptationSet :
    #        contentType = "audio"
    #        |- Representation
    #        |-   ...
    #        |- Representation
    #     |- AdaptationSet :
    #        contentType = "video"
    #        |- Representation
    #        |-   ...
    #        |- Representation
    #
    # In an mpd there could be multiple periods, each with multiple
    # adaptation sets, each with multiple representations, to form an
    # arbitrarily nested structure.
    #
    # The label_remove plugin allows to remove a label from any Adaptation Set
    # or Representation in any period.
    # This is done by selecting the desired element by means if its properties,
    # as illustrated by the following examples:
    #
    # 1) remove a label to all adaptation sets in all periods, specifying all
    #    attributes and data of the label
    #
    #    periods:
    #      - '*' : '.*'
    #        adaptationSets:
    #          - '*' : '.*'
    #            plugin_config:
    #              label:
    #                id: '0'
    #                lang: "^en$"
    #                data: "my label"
    #
    # 2) remove a label from all adaptation sets having
    #    a "video" contentType, in all periods that have an 'id'
    #    property, selecting by lang only
    #
    #    periods:
    #      - id : '.*'
    #        adaptationSets:
    #          - contentType :  "video"
    #            plugin_config:
    #              label:
    #                lang: "^en$"
    #
    # 3) remove all Label and GroupLabel from all representations, in all
    #    adaptation sets having a "video" contentType, in all periods.
    #
    #    periods:
    #      - '*' : '.*'
    #        adaptationSets:
    #          - contentType :  "video"
    #            representations:
    #              - '*' : '.*'
    #                plugin_config:
    #                  label:
    #                    id: ".*"
    #                  groupLabel:
    #                    id: ".*"
    #
    # Notice the use of regular expressions to select labels to remove.
    #
    # More details are available in manifest edit documentation.
    periods:
      - id: ".*"
        adaptationSets:
        - contentType :  "video"
          representations:
          - '*' : '.*'
            plugin_config:
              # Only remove labels in representations belonging to "video"
              # adaptation sets, whose labels contain the "Standard" string
              label:
                - data: "Standard"
