Fusionar

Un registro OCDS une todos las entregas disponibles para un proceso de contrataciones en un momento dado, y puede incluir:

  • un release compilado, que expresa el estado actual del proceso de contrataciones, mostrando solamente los valores más recientes de los campos

  • un release versionado, que expresa todos los estados históricos del proceso de contrataciones, mostrando los valores de los campos en el tiempo

Fusión es el proceso de combinar entregas individuales en un release compilado o versionado, descrito con más detalle abajo. A grandes rasgos:

  • Un release compilado se crea tomando solamente los valores más recientes de los campos de las entregas de un proceso de contrataciones específico.

  • Un release versionado se crea tomando todos los valores de los campos de las entregas en un proceso de contratación particular, copiando los metadatos sobre la entrega del cual se obtienen, y poniéndolos en orden cronológico.

Worked Example

Un agencia de compras públicas publica un release para anunciar una oportunidad en Enero 1, en la cual el valor total estimado de la compra es $1,000. En Enero 31, publican un release para corregir la información, en el cual se expande la descripción de la compra. En Febrero 5, la agencia publica un release con una enmienda a la oportunidad, en la cual el valor total estimado de la compra ha aumentado a $2,000.

La agencia decide adjudicar la oportunidad a dos de los ofertantes. El 1 de Marzo, la agencia publica una entrega anunciando que se adjudicó un contrato de $750 a la Compañía A. El 3 de Marzo, la agencia publica una entrega anunciando que se adjudicó la compañía B un contrato de $750.

A través de estas entregas individuales, la agencia da datos en tiempo real sobre el proceso de contrataciones.

En cada entrega la agencia actualiza el registro, que combina todos las entregas a la fecha. En el registro final:

  • El release compilado contiene toda la información sobre la oportunidad y adjudicaciones, utilizando el mismo esquema que utiliza una entrega.

  • El release versionado hace más fácil ver como la descripción y el valor estimado total cambiaron con el tiempo.

[
    {
        "ocid": "ocds-213czf-000-00002",
        "id": "ocds-213czf-000-00002-01-tender",
        "date": "2016-01-01T09:30:00Z",
        "language": "en",
        "tag": [
            "tender"
        ],
        "initiationType": "tender",
        "parties": [
            {
                "name": "Open Data Services",
                "identifier": {
                    "scheme": "GB-COH",
                    "id": "09506232",
                    "legalName": "Open Data Services Co-operative",
                    "uri": "https://opencorporates.com/companies/gb/09506232"
                },
                "roles": [
                    "buyer"
                ],
                "id": "GB-COH-09506232"
            }
        ],
        "buyer": {
            "id": "GB-COH-09506232",
            "name": "Open Data Services"
        },
        "tender": {
            "id": "ocds-213czf-000-00002-01-tender",
            "title": "Data merging tool",
            "description": "Data merge tool.",
            "status": "active",
            "value": {
                "amount": 1000,
                "currency": "USD"
            },
            "procurementMethod": "open",
            "awardCriteria": "bestProposal",
            "submissionMethod": [
                "electronicSubmission"
            ],
            "tenderPeriod": {
                "startDate": "2016-01-31T09:00:00Z",
                "endDate": "2016-02-15T18:00:00Z"
            },
            "awardPeriod": {
                "startDate": "2016-04-01T00:00:00Z",
                "endDate": "2016-06-01T23:59:59Z"
            }
        }
    }
]
[
    {
        "ocid": "ocds-213czf-000-00002",
        "id": "ocds-213czf-000-00002-01-tender-amendment",
        "date": "2016-02-05T10:30:00Z",
        "language": "en",
        "tag": [
            "tenderAmendment"
        ],
        "initiationType": "tender",
        "parties": [
            {
                "name": "Open Data Services",
                "identifier": {
                    "scheme": "GB-COH",
                    "id": "09506232",
                    "legalName": "Open Data Services Co-operative",
                    "uri": "https://opencorporates.com/companies/gb/09506232"
                },
                "roles": [
                    "buyer"
                ],
                "id": "GB-COH-09506232"
            }
        ],
        "buyer": {
            "id": "GB-COH-09506232",
            "name": "Open Data Services"
        },
        "tender": {
            "id": "ocds-213czf-000-00002-01-tender",
            "title": "Data merging tool",
            "description": "Creation of a data merging tool. The tool should by written in Python. Proposals should be submitted by e-mail.",
            "status": "active",
            "value": {
                "amount": 2000,
                "currency": "USD"
            },
            "procurementMethod": "open",
            "awardCriteria": "bestProposal",
            "submissionMethod": [
                "electronicSubmission"
            ],
            "tenderPeriod": {
                "startDate": "2016-01-31T09:00:00Z",
                "endDate": "2016-02-20T18:00:00Z"
            },
            "awardPeriod": {
                "startDate": "2016-04-01T00:00:00Z",
                "endDate": "2016-06-01T23:59:59Z"
            },
            "amendments": [
                {
                    "id": "amendment-1",
                    "date": "2016-02-04T09:30:00Z",
                    "rationale": "Based on feedback from potential bidders, the total budget was increased by \u00a3500, and the deadline extended",
                    "amendsReleaseID": "ocds-213czf-000-00002-01-tender",
                    "releaseID": "ocds-213czf-000-00002-01-tender-amendment"
                }
            ]
        }
    }
]
[
    {
        "ocid": "ocds-213czf-000-00002",
        "id": "ocds-213czf-000-00002-01-award1",
        "date": "2016-03-01T09:30:00Z",
        "language": "en",
        "tag": [
            "award"
        ],
        "initiationType": "tender",
        "parties": [
            {
                "name": "Open Data Services",
                "identifier": {
                    "scheme": "GB-COH",
                    "id": "09506232",
                    "legalName": "Open Data Services Co-operative",
                    "uri": "https://opencorporates.com/companies/gb/09506232"
                },
                "roles": [
                    "buyer"
                ],
                "id": "GB-COH-09506232"
            }
        ],
        "buyer": {
            "id": "GB-COH-09506232",
            "name": "Open Data Services"
        },
        "awards": [
            {
                "id": "ocds-213czf-000-00002-award-supplier-one",
                "title": "Award of contract to create the data merging tool.",
                "description": "Supplier 1 has been commissioned to create the merge tool. A separate contract will be awarded to write the documentation",
                "status": "active",
                "date": "2016-03-01T09:30:00Z",
                "value": {
                    "amount": 750,
                    "currency": "USD"
                }
            }
        ]
    }
]
[
    {
        "ocid": "ocds-213czf-000-00002",
        "id": "ocds-213czf-000-00002-01-award2",
        "date": "2016-03-03T09:30:00Z",
        "language": "en",
        "tag": [
            "award"
        ],
        "initiationType": "tender",
        "parties": [
            {
                "name": "Open Data Services",
                "identifier": {
                    "scheme": "GB-COH",
                    "id": "09506232",
                    "legalName": "Open Data Services Co-operative",
                    "uri": "https://opencorporates.com/companies/gb/09506232"
                },
                "roles": [
                    "buyer"
                ],
                "id": "GB-COH-09506232"
            }
        ],
        "buyer": {
            "id": "GB-COH-09506232",
            "name": "Open Data Services"
        },
        "awards": [
            {
                "id": "ocds-213czf-000-00002-award-supplier-two",
                "title": "Award of contract to create the data merging tool.",
                "description": "Supplier 2 has been commissioned to create the documentation. A separate contract will be awarded to create the tool",
                "status": "active",
                "date": "2016-03-03T09:30:00Z",
                "value": {
                    "amount": 750,
                    "currency": "USD"
                }
            }
        ]
    }
]
{
    "uri": "https://standard.open-contracting.org/examples/records/ocds-213czf-000-00002-merge.json",
    "publisher": {
        "scheme": "GB-COH",
        "uid": "09506232",
        "name": "Open Data Services Co-operative Limited",
        "uri": "https://standard.open-contracting.org/examples/"
    },
    "publishedDate": "2016-03-05T13:02:00Z",
    "license": "http://opendatacommons.org/licenses/pddl/1.0/",
    "publicationPolicy": "https://github.com/open-contracting/sample-data/",
    "version": "1.1",
    "packages": [
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award1.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award2.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-update.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-amendment.json"
    ],
    "records": [
        {
            "ocid": "ocds-213czf-000-00002",
            "releases": [
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award1.json#ocds-213czf-000-00002-01-award1",
                    "date": "2016-03-01T09:30:00Z",
                    "tag": [
                        "award"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award2.json#ocds-213czf-000-00002-01-award2",
                    "date": "2016-03-03T09:30:00Z",
                    "tag": [
                        "award"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender.json#ocds-213czf-000-00002-01-tender",
                    "date": "2016-01-01T09:30:00Z",
                    "tag": [
                        "tender"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-update.json#ocds-213czf-000-00002-01-tender-update",
                    "date": "2016-01-31T09:30:00Z",
                    "tag": [
                        "tenderUpdate"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-amendment.json#ocds-213czf-000-00002-01-tender-amendment",
                    "date": "2016-02-05T10:30:00Z",
                    "tag": [
                        "tenderAmendment"
                    ]
                }
            ],
            "compiledRelease": {
                "tag": [
                    "compiled"
                ],
                "id": "ocds-213czf-000-00002-2016-03-03T09:30:00Z",
                "date": "2016-03-03T09:30:00Z",
                "ocid": "ocds-213czf-000-00002",
                "language": "en",
                "initiationType": "tender",
                "parties": [
                    {
                        "id": "GB-COH-09506232",
                        "name": "Open Data Services",
                        "identifier": {
                            "scheme": "GB-COH",
                            "id": "09506232",
                            "legalName": "Open Data Services Co-operative",
                            "uri": "https://opencorporates.com/companies/gb/09506232"
                        },
                        "roles": [
                            "buyer"
                        ]
                    }
                ],
                "buyer": {
                    "id": "GB-COH-09506232",
                    "name": "Open Data Services"
                },
                "tender": {
                    "id": "ocds-213czf-000-00002-01-tender",
                    "title": "Data merging tool",
                    "description": "Creation of a data merging tool. The tool should by written in Python. Proposals should be submitted by e-mail.",
                    "status": "active",
                    "value": {
                        "amount": 2000,
                        "currency": "USD"
                    },
                    "procurementMethod": "open",
                    "awardCriteria": "bestProposal",
                    "submissionMethod": [
                        "electronicSubmission"
                    ],
                    "tenderPeriod": {
                        "startDate": "2016-01-31T09:00:00Z",
                        "endDate": "2016-02-20T18:00:00Z"
                    },
                    "awardPeriod": {
                        "startDate": "2016-04-01T00:00:00Z",
                        "endDate": "2016-06-01T23:59:59Z"
                    },
                    "amendments": [
                        {
                            "id": "amendment-1",
                            "date": "2016-02-04T09:30:00Z",
                            "rationale": "Based on feedback from potential bidders, the total budget was increased by \u00a3500, and the deadline extended",
                            "amendsReleaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseID": "ocds-213czf-000-00002-01-tender-amendment"
                        }
                    ]
                },
                "awards": [
                    {
                        "id": "ocds-213czf-000-00002-award-supplier-one",
                        "title": "Award of contract to create the data merging tool.",
                        "description": "Supplier 1 has been commissioned to create the merge tool. A separate contract will be awarded to write the documentation",
                        "status": "active",
                        "date": "2016-03-01T09:30:00Z",
                        "value": {
                            "amount": 750,
                            "currency": "USD"
                        }
                    },
                    {
                        "id": "ocds-213czf-000-00002-award-supplier-two",
                        "title": "Award of contract to create the data merging tool.",
                        "description": "Supplier 2 has been commissioned to create the documentation. A separate contract will be awarded to create the tool",
                        "status": "active",
                        "date": "2016-03-03T09:30:00Z",
                        "value": {
                            "amount": 750,
                            "currency": "USD"
                        }
                    }
                ]
            }
        }
    ]
}
{
    "uri": "https://standard.open-contracting.org/examples/records/ocds-213czf-000-00002-merge.json",
    "publisher": {
        "scheme": "GB-COH",
        "uid": "09506232",
        "name": "Open Data Services Co-operative Limited",
        "uri": "https://standard.open-contracting.org/examples/"
    },
    "publishedDate": "2016-03-05T13:02:00Z",
    "license": "http://opendatacommons.org/licenses/pddl/1.0/",
    "publicationPolicy": "https://github.com/open-contracting/sample-data/",
    "version": "1.1",
    "packages": [
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award1.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award2.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-update.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-amendment.json"
    ],
    "records": [
        {
            "ocid": "ocds-213czf-000-00002",
            "releases": [
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award1.json#ocds-213czf-000-00002-01-award1",
                    "date": "2016-03-01T09:30:00Z",
                    "tag": [
                        "award"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award2.json#ocds-213czf-000-00002-01-award2",
                    "date": "2016-03-03T09:30:00Z",
                    "tag": [
                        "award"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender.json#ocds-213czf-000-00002-01-tender",
                    "date": "2016-01-01T09:30:00Z",
                    "tag": [
                        "tender"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-update.json#ocds-213czf-000-00002-01-tender-update",
                    "date": "2016-01-31T09:30:00Z",
                    "tag": [
                        "tenderUpdate"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-amendment.json#ocds-213czf-000-00002-01-tender-amendment",
                    "date": "2016-02-05T10:30:00Z",
                    "tag": [
                        "tenderAmendment"
                    ]
                }
            ],
            "compiledRelease": {
                "tag": [
                    "compiled"
                ],
                "id": "ocds-213czf-000-00002-2016-03-03T09:30:00Z",
                "date": "2016-03-03T09:30:00Z",
                "ocid": "ocds-213czf-000-00002",
                "language": "en",
                "initiationType": "tender",
                "parties": [
                    {
                        "id": "GB-COH-09506232",
                        "name": "Open Data Services",
                        "identifier": {
                            "scheme": "GB-COH",
                            "id": "09506232",
                            "legalName": "Open Data Services Co-operative",
                            "uri": "https://opencorporates.com/companies/gb/09506232"
                        },
                        "roles": [
                            "buyer"
                        ]
                    }
                ],
                "buyer": {
                    "id": "GB-COH-09506232",
                    "name": "Open Data Services"
                },
                "tender": {
                    "id": "ocds-213czf-000-00002-01-tender",
                    "title": "Data merging tool",
                    "description": "Creation of a data merging tool. The tool should by written in Python. Proposals should be submitted by e-mail.",
                    "status": "active",
                    "value": {
                        "amount": 2000,
                        "currency": "USD"
                    },
                    "procurementMethod": "open",
                    "awardCriteria": "bestProposal",
                    "submissionMethod": [
                        "electronicSubmission"
                    ],
                    "tenderPeriod": {
                        "startDate": "2016-01-31T09:00:00Z",
                        "endDate": "2016-02-20T18:00:00Z"
                    },
                    "awardPeriod": {
                        "startDate": "2016-04-01T00:00:00Z",
                        "endDate": "2016-06-01T23:59:59Z"
                    },
                    "amendments": [
                        {
                            "id": "amendment-1",
                            "date": "2016-02-04T09:30:00Z",
                            "rationale": "Based on feedback from potential bidders, the total budget was increased by \u00a3500, and the deadline extended",
                            "amendsReleaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseID": "ocds-213czf-000-00002-01-tender-amendment"
                        }
                    ]
                },
                "awards": [
                    {
                        "id": "ocds-213czf-000-00002-award-supplier-one",
                        "title": "Award of contract to create the data merging tool.",
                        "description": "Supplier 1 has been commissioned to create the merge tool. A separate contract will be awarded to write the documentation",
                        "status": "active",
                        "date": "2016-03-01T09:30:00Z",
                        "value": {
                            "amount": 750,
                            "currency": "USD"
                        }
                    },
                    {
                        "id": "ocds-213czf-000-00002-award-supplier-two",
                        "title": "Award of contract to create the data merging tool.",
                        "description": "Supplier 2 has been commissioned to create the documentation. A separate contract will be awarded to create the tool",
                        "status": "active",
                        "date": "2016-03-03T09:30:00Z",
                        "value": {
                            "amount": 750,
                            "currency": "USD"
                        }
                    }
                ]
            },
            "versionedRelease": {
                "ocid": "ocds-213czf-000-00002",
                "language": [
                    {
                        "releaseID": "ocds-213czf-000-00002-01-tender",
                        "releaseDate": "2016-01-01T09:30:00Z",
                        "releaseTag": [
                            "tender"
                        ],
                        "value": "en"
                    }
                ],
                "initiationType": [
                    {
                        "releaseID": "ocds-213czf-000-00002-01-tender",
                        "releaseDate": "2016-01-01T09:30:00Z",
                        "releaseTag": [
                            "tender"
                        ],
                        "value": "tender"
                    }
                ],
                "parties": [
                    {
                        "id": "GB-COH-09506232",
                        "name": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "Open Data Services"
                            }
                        ],
                        "identifier": {
                            "scheme": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender",
                                    "releaseDate": "2016-01-01T09:30:00Z",
                                    "releaseTag": [
                                        "tender"
                                    ],
                                    "value": "GB-COH"
                                }
                            ],
                            "id": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender",
                                    "releaseDate": "2016-01-01T09:30:00Z",
                                    "releaseTag": [
                                        "tender"
                                    ],
                                    "value": "09506232"
                                }
                            ],
                            "legalName": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender",
                                    "releaseDate": "2016-01-01T09:30:00Z",
                                    "releaseTag": [
                                        "tender"
                                    ],
                                    "value": "Open Data Services Co-operative"
                                }
                            ],
                            "uri": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender",
                                    "releaseDate": "2016-01-01T09:30:00Z",
                                    "releaseTag": [
                                        "tender"
                                    ],
                                    "value": "https://opencorporates.com/companies/gb/09506232"
                                }
                            ]
                        },
                        "roles": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": [
                                    "buyer"
                                ]
                            }
                        ]
                    }
                ],
                "buyer": {
                    "id": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "GB-COH-09506232"
                        }
                    ],
                    "name": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "Open Data Services"
                        }
                    ]
                },
                "tender": {
                    "id": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "ocds-213czf-000-00002-01-tender"
                        }
                    ],
                    "title": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "Data merging tool"
                        }
                    ],
                    "description": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "Data merge tool."
                        },
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender-update",
                            "releaseDate": "2016-01-31T09:30:00Z",
                            "releaseTag": [
                                "tenderUpdate"
                            ],
                            "value": "Creation of a data merging tool. The tool should by written in Python. Proposals should be submitted by e-mail."
                        }
                    ],
                    "status": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "active"
                        }
                    ],
                    "value": {
                        "amount": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": 1000
                            },
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                "releaseDate": "2016-02-05T10:30:00Z",
                                "releaseTag": [
                                    "tenderAmendment"
                                ],
                                "value": 2000
                            }
                        ],
                        "currency": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "USD"
                            }
                        ]
                    },
                    "procurementMethod": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "open"
                        }
                    ],
                    "awardCriteria": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "bestProposal"
                        }
                    ],
                    "submissionMethod": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": [
                                "electronicSubmission"
                            ]
                        }
                    ],
                    "tenderPeriod": {
                        "startDate": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "2016-01-31T09:00:00Z"
                            }
                        ],
                        "endDate": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "2016-02-15T18:00:00Z"
                            },
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                "releaseDate": "2016-02-05T10:30:00Z",
                                "releaseTag": [
                                    "tenderAmendment"
                                ],
                                "value": "2016-02-20T18:00:00Z"
                            }
                        ]
                    },
                    "awardPeriod": {
                        "startDate": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "2016-04-01T00:00:00Z"
                            }
                        ],
                        "endDate": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "2016-06-01T23:59:59Z"
                            }
                        ]
                    },
                    "amendments": [
                        {
                            "id": "amendment-1",
                            "date": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                    "releaseDate": "2016-02-05T10:30:00Z",
                                    "releaseTag": [
                                        "tenderAmendment"
                                    ],
                                    "value": "2016-02-04T09:30:00Z"
                                }
                            ],
                            "rationale": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                    "releaseDate": "2016-02-05T10:30:00Z",
                                    "releaseTag": [
                                        "tenderAmendment"
                                    ],
                                    "value": "Based on feedback from potential bidders, the total budget was increased by \u00a3500, and the deadline extended"
                                }
                            ],
                            "amendsReleaseID": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                    "releaseDate": "2016-02-05T10:30:00Z",
                                    "releaseTag": [
                                        "tenderAmendment"
                                    ],
                                    "value": "ocds-213czf-000-00002-01-tender"
                                }
                            ],
                            "releaseID": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                    "releaseDate": "2016-02-05T10:30:00Z",
                                    "releaseTag": [
                                        "tenderAmendment"
                                    ],
                                    "value": "ocds-213czf-000-00002-01-tender-amendment"
                                }
                            ]
                        }
                    ]
                },
                "awards": [
                    {
                        "id": "ocds-213czf-000-00002-award-supplier-one",
                        "title": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award1",
                                "releaseDate": "2016-03-01T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "Award of contract to create the data merging tool."
                            }
                        ],
                        "description": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award1",
                                "releaseDate": "2016-03-01T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "Supplier 1 has been commissioned to create the merge tool. A separate contract will be awarded to write the documentation"
                            }
                        ],
                        "status": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award1",
                                "releaseDate": "2016-03-01T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "active"
                            }
                        ],
                        "date": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award1",
                                "releaseDate": "2016-03-01T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "2016-03-01T09:30:00Z"
                            }
                        ],
                        "value": {
                            "amount": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-award1",
                                    "releaseDate": "2016-03-01T09:30:00Z",
                                    "releaseTag": [
                                        "award"
                                    ],
                                    "value": 750
                                }
                            ],
                            "currency": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-award1",
                                    "releaseDate": "2016-03-01T09:30:00Z",
                                    "releaseTag": [
                                        "award"
                                    ],
                                    "value": "USD"
                                }
                            ]
                        }
                    },
                    {
                        "id": "ocds-213czf-000-00002-award-supplier-two",
                        "title": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award2",
                                "releaseDate": "2016-03-03T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "Award of contract to create the data merging tool."
                            }
                        ],
                        "description": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award2",
                                "releaseDate": "2016-03-03T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "Supplier 2 has been commissioned to create the documentation. A separate contract will be awarded to create the tool"
                            }
                        ],
                        "status": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award2",
                                "releaseDate": "2016-03-03T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "active"
                            }
                        ],
                        "date": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award2",
                                "releaseDate": "2016-03-03T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "2016-03-03T09:30:00Z"
                            }
                        ],
                        "value": {
                            "amount": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-award2",
                                    "releaseDate": "2016-03-03T09:30:00Z",
                                    "releaseTag": [
                                        "award"
                                    ],
                                    "value": 750
                                }
                            ],
                            "currency": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-award2",
                                    "releaseDate": "2016-03-03T09:30:00Z",
                                    "releaseTag": [
                                        "award"
                                    ],
                                    "value": "USD"
                                }
                            ]
                        }
                    }
                ]
            }
        }
    ]
}

Especificaciones de fusión (merging)

Campos descartados

En el esquema de entrega, "omitWhenMerged": true se declara en campos que se deben descartar cuando se hace la fusión. Estos actualmente son: id, date y tag.

  • Para un release compilado:

    • Tanto los campos como los valores se descartan porque son metadatos sobre entregas individuales; los releases compilados reemplazan estos con sus propios metadatos.

  • Para un release versionado:

    • Los campos se descartan, pero sus valores se mueven, como se describe abajo, para indicar de cuáles entregas se obtiene el valor del campo.

Si omitWhenMerged es false, ignórelo.

Nota

El release compilado actualmente usa el mismo esquema que la entrega OCDS, lo cual significa que los campos id, date y tag son requisitos en un release compilado. Invitamos a discutir sobre si es necesario hacer cambios a estos requisitos en un esquema separado de release compilado en el issue #330 <https://github.com/open-contracting/standard/issues/330>, y sobre cómo identificar y poner fecha a releases compilados y versionados en el issue #834 <https://github.com/open-contracting/standard/issues/834>.

Mientras tanto, una solución intermedia es poner tag igual a ["compiled"], date con la fecha de la entrega más reciente, y id igual a {ocid}-{date}, como en la referencia de implementación <#reference-implementation>__ de la rutina de fusión (merge).

Valores versionados

Para convertir los valores de un campo de una entrega a un versioned value, debe:

  1. Crear un objeto JSON vacío

  2. Ajustar los campos releaseID, releaseDate y releaseTag a los valores id, date y tag de la entrega

  3. Ajustar el valor del campo (value) al valor del campo en la entrega

Así, un versioned value describe los valores de un campo en una entrega específica.

Por ejemplo, en el ejemplo de trabajo anterior, el valor estimado de compras fue $1,000 en una entrega (tender/value/amount fue 1000). Siguiendo los pasos de arriba, el valor versionado es:

{
  "releaseID": "ocds-213czf-000-00002-01-tender",
  "releaseDate": "2016-01-01T09:30:00Z",
  "releaseTag": [
    "tender"
  ],
  "value": 1000
}

En un versioned release, con algunas excepciones, un valor del campo se reemplaza con una lista de valores versionados, los cuales deben estar en orden cronológico ordenados por releaseDate.

Por ejemplo, en el ejemplo de trabajo anterior, el valor estimado fue $1,000 en una entrega publicada el 1 de Enero de 2016 y después $2,000 en una entrega publicada el 5 de Febrero de 2016. En un release versionado, esto se serializa de la siguiente manera:

{
    "amount": [
        {
            "releaseID": "ocds-213czf-000-00002-01-tender",
            "releaseDate": "2016-01-01T09:30:00Z",
            "releaseTag": [
                "tender"
            ],
            "value": 1000
        },
        {
            "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
            "releaseDate": "2016-02-05T10:30:00Z",
            "releaseTag": [
                "tenderAmendment"
            ],
            "value": 2000
        }
    ],
    "currency": [
        {
            "releaseID": "ocds-213czf-000-00002-01-tender",
            "releaseDate": "2016-01-01T09:30:00Z",
            "releaseTag": [
                "tender"
            ],
            "value": "USD"
        }
    ]
}
{
    "uri": "https://standard.open-contracting.org/examples/records/ocds-213czf-000-00002-merge.json",
    "publisher": {
        "scheme": "GB-COH",
        "uid": "09506232",
        "name": "Open Data Services Co-operative Limited",
        "uri": "https://standard.open-contracting.org/examples/"
    },
    "publishedDate": "2016-03-05T13:02:00Z",
    "license": "http://opendatacommons.org/licenses/pddl/1.0/",
    "publicationPolicy": "https://github.com/open-contracting/sample-data/",
    "version": "1.1",
    "packages": [
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award1.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award2.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-update.json",
        "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-amendment.json"
    ],
    "records": [
        {
            "ocid": "ocds-213czf-000-00002",
            "releases": [
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award1.json#ocds-213czf-000-00002-01-award1",
                    "date": "2016-03-01T09:30:00Z",
                    "tag": [
                        "award"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-award2.json#ocds-213czf-000-00002-01-award2",
                    "date": "2016-03-03T09:30:00Z",
                    "tag": [
                        "award"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender.json#ocds-213czf-000-00002-01-tender",
                    "date": "2016-01-01T09:30:00Z",
                    "tag": [
                        "tender"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-update.json#ocds-213czf-000-00002-01-tender-update",
                    "date": "2016-01-31T09:30:00Z",
                    "tag": [
                        "tenderUpdate"
                    ]
                },
                {
                    "url": "https://standard.open-contracting.org/examples/releases/ocds-213czf-000-00002-01-tender-amendment.json#ocds-213czf-000-00002-01-tender-amendment",
                    "date": "2016-02-05T10:30:00Z",
                    "tag": [
                        "tenderAmendment"
                    ]
                }
            ],
            "compiledRelease": {
                "tag": [
                    "compiled"
                ],
                "id": "ocds-213czf-000-00002-2016-03-03T09:30:00Z",
                "date": "2016-03-03T09:30:00Z",
                "ocid": "ocds-213czf-000-00002",
                "language": "en",
                "initiationType": "tender",
                "parties": [
                    {
                        "id": "GB-COH-09506232",
                        "name": "Open Data Services",
                        "identifier": {
                            "scheme": "GB-COH",
                            "id": "09506232",
                            "legalName": "Open Data Services Co-operative",
                            "uri": "https://opencorporates.com/companies/gb/09506232"
                        },
                        "roles": [
                            "buyer"
                        ]
                    }
                ],
                "buyer": {
                    "id": "GB-COH-09506232",
                    "name": "Open Data Services"
                },
                "tender": {
                    "id": "ocds-213czf-000-00002-01-tender",
                    "title": "Data merging tool",
                    "description": "Creation of a data merging tool. The tool should by written in Python. Proposals should be submitted by e-mail.",
                    "status": "active",
                    "value": {
                        "amount": 2000,
                        "currency": "USD"
                    },
                    "procurementMethod": "open",
                    "awardCriteria": "bestProposal",
                    "submissionMethod": [
                        "electronicSubmission"
                    ],
                    "tenderPeriod": {
                        "startDate": "2016-01-31T09:00:00Z",
                        "endDate": "2016-02-20T18:00:00Z"
                    },
                    "awardPeriod": {
                        "startDate": "2016-04-01T00:00:00Z",
                        "endDate": "2016-06-01T23:59:59Z"
                    },
                    "amendments": [
                        {
                            "id": "amendment-1",
                            "date": "2016-02-04T09:30:00Z",
                            "rationale": "Based on feedback from potential bidders, the total budget was increased by \u00a3500, and the deadline extended",
                            "amendsReleaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseID": "ocds-213czf-000-00002-01-tender-amendment"
                        }
                    ]
                },
                "awards": [
                    {
                        "id": "ocds-213czf-000-00002-award-supplier-one",
                        "title": "Award of contract to create the data merging tool.",
                        "description": "Supplier 1 has been commissioned to create the merge tool. A separate contract will be awarded to write the documentation",
                        "status": "active",
                        "date": "2016-03-01T09:30:00Z",
                        "value": {
                            "amount": 750,
                            "currency": "USD"
                        }
                    },
                    {
                        "id": "ocds-213czf-000-00002-award-supplier-two",
                        "title": "Award of contract to create the data merging tool.",
                        "description": "Supplier 2 has been commissioned to create the documentation. A separate contract will be awarded to create the tool",
                        "status": "active",
                        "date": "2016-03-03T09:30:00Z",
                        "value": {
                            "amount": 750,
                            "currency": "USD"
                        }
                    }
                ]
            },
            "versionedRelease": {
                "ocid": "ocds-213czf-000-00002",
                "language": [
                    {
                        "releaseID": "ocds-213czf-000-00002-01-tender",
                        "releaseDate": "2016-01-01T09:30:00Z",
                        "releaseTag": [
                            "tender"
                        ],
                        "value": "en"
                    }
                ],
                "initiationType": [
                    {
                        "releaseID": "ocds-213czf-000-00002-01-tender",
                        "releaseDate": "2016-01-01T09:30:00Z",
                        "releaseTag": [
                            "tender"
                        ],
                        "value": "tender"
                    }
                ],
                "parties": [
                    {
                        "id": "GB-COH-09506232",
                        "name": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "Open Data Services"
                            }
                        ],
                        "identifier": {
                            "scheme": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender",
                                    "releaseDate": "2016-01-01T09:30:00Z",
                                    "releaseTag": [
                                        "tender"
                                    ],
                                    "value": "GB-COH"
                                }
                            ],
                            "id": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender",
                                    "releaseDate": "2016-01-01T09:30:00Z",
                                    "releaseTag": [
                                        "tender"
                                    ],
                                    "value": "09506232"
                                }
                            ],
                            "legalName": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender",
                                    "releaseDate": "2016-01-01T09:30:00Z",
                                    "releaseTag": [
                                        "tender"
                                    ],
                                    "value": "Open Data Services Co-operative"
                                }
                            ],
                            "uri": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender",
                                    "releaseDate": "2016-01-01T09:30:00Z",
                                    "releaseTag": [
                                        "tender"
                                    ],
                                    "value": "https://opencorporates.com/companies/gb/09506232"
                                }
                            ]
                        },
                        "roles": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": [
                                    "buyer"
                                ]
                            }
                        ]
                    }
                ],
                "buyer": {
                    "id": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "GB-COH-09506232"
                        }
                    ],
                    "name": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "Open Data Services"
                        }
                    ]
                },
                "tender": {
                    "id": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "ocds-213czf-000-00002-01-tender"
                        }
                    ],
                    "title": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "Data merging tool"
                        }
                    ],
                    "description": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "Data merge tool."
                        },
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender-update",
                            "releaseDate": "2016-01-31T09:30:00Z",
                            "releaseTag": [
                                "tenderUpdate"
                            ],
                            "value": "Creation of a data merging tool. The tool should by written in Python. Proposals should be submitted by e-mail."
                        }
                    ],
                    "status": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "active"
                        }
                    ],
                    "value": {
                        "amount": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": 1000
                            },
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                "releaseDate": "2016-02-05T10:30:00Z",
                                "releaseTag": [
                                    "tenderAmendment"
                                ],
                                "value": 2000
                            }
                        ],
                        "currency": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "USD"
                            }
                        ]
                    },
                    "procurementMethod": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "open"
                        }
                    ],
                    "awardCriteria": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": "bestProposal"
                        }
                    ],
                    "submissionMethod": [
                        {
                            "releaseID": "ocds-213czf-000-00002-01-tender",
                            "releaseDate": "2016-01-01T09:30:00Z",
                            "releaseTag": [
                                "tender"
                            ],
                            "value": [
                                "electronicSubmission"
                            ]
                        }
                    ],
                    "tenderPeriod": {
                        "startDate": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "2016-01-31T09:00:00Z"
                            }
                        ],
                        "endDate": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "2016-02-15T18:00:00Z"
                            },
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                "releaseDate": "2016-02-05T10:30:00Z",
                                "releaseTag": [
                                    "tenderAmendment"
                                ],
                                "value": "2016-02-20T18:00:00Z"
                            }
                        ]
                    },
                    "awardPeriod": {
                        "startDate": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "2016-04-01T00:00:00Z"
                            }
                        ],
                        "endDate": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-tender",
                                "releaseDate": "2016-01-01T09:30:00Z",
                                "releaseTag": [
                                    "tender"
                                ],
                                "value": "2016-06-01T23:59:59Z"
                            }
                        ]
                    },
                    "amendments": [
                        {
                            "id": "amendment-1",
                            "date": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                    "releaseDate": "2016-02-05T10:30:00Z",
                                    "releaseTag": [
                                        "tenderAmendment"
                                    ],
                                    "value": "2016-02-04T09:30:00Z"
                                }
                            ],
                            "rationale": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                    "releaseDate": "2016-02-05T10:30:00Z",
                                    "releaseTag": [
                                        "tenderAmendment"
                                    ],
                                    "value": "Based on feedback from potential bidders, the total budget was increased by \u00a3500, and the deadline extended"
                                }
                            ],
                            "amendsReleaseID": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                    "releaseDate": "2016-02-05T10:30:00Z",
                                    "releaseTag": [
                                        "tenderAmendment"
                                    ],
                                    "value": "ocds-213czf-000-00002-01-tender"
                                }
                            ],
                            "releaseID": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-tender-amendment",
                                    "releaseDate": "2016-02-05T10:30:00Z",
                                    "releaseTag": [
                                        "tenderAmendment"
                                    ],
                                    "value": "ocds-213czf-000-00002-01-tender-amendment"
                                }
                            ]
                        }
                    ]
                },
                "awards": [
                    {
                        "id": "ocds-213czf-000-00002-award-supplier-one",
                        "title": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award1",
                                "releaseDate": "2016-03-01T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "Award of contract to create the data merging tool."
                            }
                        ],
                        "description": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award1",
                                "releaseDate": "2016-03-01T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "Supplier 1 has been commissioned to create the merge tool. A separate contract will be awarded to write the documentation"
                            }
                        ],
                        "status": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award1",
                                "releaseDate": "2016-03-01T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "active"
                            }
                        ],
                        "date": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award1",
                                "releaseDate": "2016-03-01T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "2016-03-01T09:30:00Z"
                            }
                        ],
                        "value": {
                            "amount": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-award1",
                                    "releaseDate": "2016-03-01T09:30:00Z",
                                    "releaseTag": [
                                        "award"
                                    ],
                                    "value": 750
                                }
                            ],
                            "currency": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-award1",
                                    "releaseDate": "2016-03-01T09:30:00Z",
                                    "releaseTag": [
                                        "award"
                                    ],
                                    "value": "USD"
                                }
                            ]
                        }
                    },
                    {
                        "id": "ocds-213czf-000-00002-award-supplier-two",
                        "title": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award2",
                                "releaseDate": "2016-03-03T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "Award of contract to create the data merging tool."
                            }
                        ],
                        "description": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award2",
                                "releaseDate": "2016-03-03T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "Supplier 2 has been commissioned to create the documentation. A separate contract will be awarded to create the tool"
                            }
                        ],
                        "status": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award2",
                                "releaseDate": "2016-03-03T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "active"
                            }
                        ],
                        "date": [
                            {
                                "releaseID": "ocds-213czf-000-00002-01-award2",
                                "releaseDate": "2016-03-03T09:30:00Z",
                                "releaseTag": [
                                    "award"
                                ],
                                "value": "2016-03-03T09:30:00Z"
                            }
                        ],
                        "value": {
                            "amount": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-award2",
                                    "releaseDate": "2016-03-03T09:30:00Z",
                                    "releaseTag": [
                                        "award"
                                    ],
                                    "value": 750
                                }
                            ],
                            "currency": [
                                {
                                    "releaseID": "ocds-213czf-000-00002-01-award2",
                                    "releaseDate": "2016-03-03T09:30:00Z",
                                    "releaseTag": [
                                        "award"
                                    ],
                                    "value": "USD"
                                }
                            ]
                        }
                    }
                ]
            }
        }
    ]
}

La estructura del release versionado se describe de acuerdo al esquema de release versionado; note que el valor del campo ocid no está versionado.

Rutina de fusión (merge)

Para crear un release compilado o versionado, debe de:

  1. Obtener todas las entregas con el mismo valor ocid

  2. Ordenar las entregas en orden cronológico por fecha (date)

  3. Crear un objeto JSON vacío para releases compilados o versionados

  4. Fusionar cada entrega (input), en orden, en el objeto JSON (output), de la siguiente manera:

Valores de objeto

La entrega es un objeto por si mismo, por lo que este caso se encuentra primero.

Si el objeto esta vacío en input, no debe hacer nada. Por cada campo dentro del objeto en input:

  • Para un release compilado:

    • Si el campo en input tiene el valor null, quite el campo del objeto en output, si está presente

    • Si el campo no está en output, añada el campo al objeto en output y establézcalo al valor presente en input

    • Si el campo está en output, fusione los valores de los campos en output e input de acuerdo a la rutina de fusión

  • Para un release versionado:

    • Fusione los valores de los campos en output e input de acuerdo a la rutina de fusión; si hay un resultado, agregue el campo al objeto en output si no esta agregado ya, y establezca su valor al resultado

Valores literales

Si el valor input no es un objeto ni una lista, entonces:

  • Para un release compilado:

    • Si el valor input es diferente al valor output, reemplace el valor output con el valor input

  • Para un release versionado:

    • Si no hay valor output, establezca el valor output como una lista JSON vacía, convierta el valor output a un valor versionado, y adjúntelo a la nueva lista de valores versionados en output

    • Si el valor input es diferente al valor del campo value del valor versionado más reciente en output, convierta el valor input a un valor versionado, y adjúntelo a la lista de valores versionados en output

Valores de lista

Si la lista input contiene algo más que objetos, trate la lista como un valor literal. De otra manera, hay dos sub rutinas para listas de objetos: fusión de lista completa y fusión de identificadores

Fusionar la lista completa

Una lista input debe tratarse como un valor literal si el campo correspondiente en una copia desreferenciada del esquema de entrega tiene "array" como type y si cualquiera de las siguientes son verdaderas:

  • El campo tiene “wholeListMerge”: true`

  • El campo establece items/type, y tiene cualquier cosa menos "object" en su items/type

  • El campo tiene "object" en items/type, establece items/properties, y no tiene el campo id en items/properties

Fusión de identificador

Este caso se encuentra si las condiciones anteriores no se cumplen. Si la lista está vacía en input, no haga nada. Para cada objeto en la lista input:

  • Para un release compilado:

    • Si hay un objeto en la lista en output con el mismo valor de id en el objeto input, fusione los objetos iguales en input y output de acuerdo a la rutina de fusión

    • De otra manera, adjunte el objeto en input a la lista en output

  • Para un release versionado:

    • Si hay un objeto en la lista en output con el mismo valor de id que en el objeto en input, fusione los objetos iguales en input y output de acuerdo a la rutina de fusión, menos el campo id, que no está versionado y se debe mantener igual

    • De otra forma, fusione un objeto JSON vacío y el objeto en input de acuerdo a la rutina de fusión menos el campo id, que no está versionado y se debe mantener igual, y adjunte el resultado a la lista en output

Nota

En ese caso, para quitar un objeto de la lista, necesitas establecer cada uno de sus campos a null. Invitamos a discutir sobre cómo quitar objetos de listas en el issue #232 <https://github.com/open-contracting/standard/issues/232>__.

Nota

En el esquema de entrega, "versionId": true`` se declara en los campos ``id`` que deben estar versionados. Esto es por conveniencia y debería retirarse en versiones futuras de OCDS (vea el issue#812 https://github.com/open-contracting/standard/issues/812`__). Si se declara "versionId": true en el campo id de un objeto en una lista, es ignorado. "versionId": false no tiene ningún significado y es ignorado.

Implementación de referencia

Una implementación de referencia de la rutina de fusión en Python está disponible en GitHub. Recomendamos fuertemente que, para cualquier re-implementación, lea el código comentado y use los casos de test, para asegurar que sea correcto.