def METHOD_NAME(labels: dict[str, Any]) -> dict[str, Any]:
    """Creates a metadata object 'simcore.service.*' labels such as
    {
        "service.settings": { ... }
        "service.value": 42
    }
    """
    meta = {}
    for key in labels:
        if key.startswith("simcore.service."):
            value = labels[key].strip()
            try:
                value = json.loads(value)
            except json.decoder.JSONDecodeError:
                # e.g. key=value where value is a raw name
                pass
            meta.update(**{key.removeprefix("simcore."): value})
    return meta