{"title": "Linking Metadata During Submission", "status": "open", "content": [{"file": "/docs/source/referencing_data.rst", "status": "open", "options": {"filetype": "rst", "collapsible": false, "default_open": true, "convert_ext_links": true, "initial_header_level": 2}, "consortia": [{"display_title": "SMaHT", "status": "open", "uuid": "358aed10-9b9d-4e26-ab84-4bd162da182b", "@type": ["Consortium", "Item"], "@id": "/consortia/358aed10-9b9d-4e26-ab84-4bd162da182b/", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "identifier": "referencing_data", "date_created": "2024-02-28T17:30:38.918784+00:00", "section_type": "Page Section", "last_modified": {"modified_by": {"error": "no view permissions"}, "date_modified": "2026-03-28T15:48:30.480207+00:00"}, "schema_version": "1", "submission_centers": [{"status": "open", "uuid": "9626d82e-8110-4213-ac75-0a50adf890ff", "display_title": "HMS DAC", "@type": ["SubmissionCenter", "Item"], "@id": "/submission-centers/9626d82e-8110-4213-ac75-0a50adf890ff/", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "@id": "/static-sections/6206008f-9288-4156-b55d-52a75f5332e8/", "@type": ["StaticSection", "UserContent", "Item"], "uuid": "6206008f-9288-4156-b55d-52a75f5332e8", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}, "display_title": "referencing_data", "content_as_html": "<div class=\"rst-container\"><h2>Linking Metadata During Submission</h2><p>The SMaHT metadata model is composed of database objects that can be linked to each other to represent relationships.</p><p>These links are <strong>extremely important</strong>; without them, we would not be able to determine how files were generated from specific assay types or what samples come from which donors.</p><p>The metadata model allows us to link a tissue to the donor it was taken from or indicate that an aligned BAM was <code>derived_from</code> an unaligned FASTQ file. This linking is accomplished via \u201cLinkTo\u201d properties that allow objects to refer to other objects.</p><h3>When and how do I \"LinkTo\" another object?</h3><p>In the submission spreadsheet (See <a class=\"reference external\" href=\"/docs/submission/getting-started-with-submissions\">Getting Started with Submissions</a>), columns with <em>italicized</em> names indicate LinkTo fields. For example, Library items require links to Analyte and Assay items, as shown in the image below.</p><div class=\"line-block\"><div class=\"line\"><br/></div></div><img alt=\"Submission spreadsheet Library screenshot\" src=\"/static/img/docs/submission_spreadsheet_example_library.jpg\"/><div class=\"line-block\"><div class=\"line\"><br/></div></div><p>To link two items together, simply grab the identifier for the item you are linking to and copy it into the corresponding cell in the spreadsheet. In the example below, the Library item is linking to an Analyte item in the same workbook using its <code>submitted_id</code> and is linking to an assay on the data portal using its <code>identifier</code>.</p><div class=\"line-block\"><div class=\"line\"><br/></div></div><img alt=\"Linking example diagram\" src=\"/static/img/docs/link_to_example_diagram.jpg\"/><div class=\"line-block\"><div class=\"line\"><br/></div></div><h3>Finding the correct IDs to submit</h3><p>LinkTo property values must uniquely identify an object, either through a <code>submitted_id</code> value from another row and/or sheet in the submission workbook or an identifying property for an existing object on the portal (which could also be a <code>submitted_id</code>).</p><h4>For objects or rows in your workbook</h4><p>When linking items that are already on your submission workbook in another row and/or sheet, please use the <code>submitted_id</code> value as the unique identifier for that item. Refer to the image above with the link from Library to Analyte to see an example of this.</p><h4>For objects already on the data portal</h4><p>To find an existing identifier on the portal, please use the links provided below. Each link will bring you to a table with all available items of that given item type. The \u201cSubmitted ID\u201d and \u201cIdentifier\u201d columns serve as unique identifiers for that item, either of which can be used as a LinkTo property value.</p><p>The links to the different reference tables can also be found right from the submission spreadsheet itself:</p><div class=\"line-block\"><div class=\"line\"><br/></div></div><img alt=\"Linking example diagram\" src=\"/static/img/docs/submitr_spreadsheet_item_dropdown_example.jpg\"/><div class=\"line-block\"><div class=\"line\"><br/></div></div><div class=\"admonition note\"><p class=\"first admonition-title\">Note</p><p class=\"last\">You need to be logged in to the SMaHT data portal in order to see the data at the provided links.</p></div><div class=\"line-block\"><div class=\"line\"><br/></div></div><h4>Links to data tables to find identifiers on the portal</h4><hr/><div class=\"table-responsive\"><table class=\"table table-borderless table-sm text-start\" style=\"min-width: 340px;\"><thead class=\"thead-smaht\"><tr class=\"\"><th class=\"px-2\">Data Type</th><th class=\"px-2\">LinkTo Property Options</th></tr></thead><tbody class=\"table-border-inner\"><tr class=\"\"><td class=\"px-2 d-flex flex-column\"><a href=\"/search/?type=Donor\"><b>Donors</b></a><a href=\"/search/?type=Tissue\"><b>Tissues</b></a><a href=\"/search/?type=CellCulture\"><b>CellCultures</b></a><a href=\"/search/?type=PreparationKit\"><b>PreparationKit</b></a><a href=\"/search/?type=Treatment\"><b>Treatment</b></a><a href=\"/search/?type=LibraryPreparation\"><b>LibraryPreparation</b></a><a href=\"/search/?type=AnalytePreparation\"><b>AnalytePreparation</b></a><a href=\"/search/?type=DonorSpecificAssembly\"><b>DonorSpecificAssembly</b></a><a href=\"/search/?type=Software\"><b>Software</b></a></td><td class=\"px-2\">                    Submitted ID                </td></tr><tr class=\"\"><td class=\"px-2 d-flex flex-column\"><a href=\"/search/?type=Sequencer\"><b>Sequencers</b></a><a href=\"/search/?type=Assay\"><b>Assays</b></a><a href=\"/search/?type=ReferenceGenome\"><b>ReferenceGenomes</b></a><b>FileFormats</b><ul class=\"mt-0\"><li>For <a href=\"/search/?type=FileFormat&amp;valid_item_types=UnalignedReads\">UnalignedReads</a></li><li>For <a href=\"/search/?type=FileFormat&amp;valid_item_types=AlignedReads\">AlignedReads</a></li><li>For <a href=\"/search/?type=FileFormat&amp;valid_item_types=VariantCalls\">VariantCalls</a></li><li>For <a href=\"/search/?type=FileFormat&amp;valid_item_types=SupplementaryFile\">SupplementaryFile</a></li></ul></td><td class=\"px-2\">                    Identifier                </td></tr></tbody></table></div><div class=\"admonition note\"><p class=\"first admonition-title\">Note</p><p class=\"last\">The <code>smaht-submitr</code> tool and SMaHT data portal will automatically ensure that the referenced objects actually exist within SMaHT data portal or are defined within the spreadsheet itself; if this is not the case, an error will be returned.</p></div><h3>Overview of the data model</h3><p>As mentioned previously, metadata in the portal is connected by linking objects of a variety of item types together. A simplified version of the data model is shown below, with items linking together to indicate how files were derived from experiments, samples, and donors. This structure allows for clear interpretation of the origin of sequence data.</p><div class=\"line-block\"><div class=\"line\"><br/></div></div><img alt=\"Data Model\" src=\"/static/img/docs/data_model.png\"/></div>", "content": "==================================\nLinking Metadata During Submission\n==================================\n\nThe SMaHT metadata model is composed of database objects that can be linked to each other to represent relationships.\n\nThese links are **extremely important**; without them, we would not be able to determine how files were generated from specific assay types or what samples come from which donors.\n\nThe metadata model allows us to link a tissue to the donor it was taken from or indicate that an aligned BAM was ``derived_from`` an unaligned FASTQ file. This linking is accomplished via \u201cLinkTo\u201d properties that allow objects to refer to other objects.\n\n\nWhen and how do I \"LinkTo\" another object?\n------------------------------------------\nIn the submission spreadsheet (See `Getting Started with Submissions </docs/submission/getting-started-with-submissions>`_), columns with *italicized* names indicate LinkTo fields. For example, Library items require links to Analyte and Assay items, as shown in the image below.\n\n|\n\n.. image:: /static/img/docs/submission_spreadsheet_example_library.jpg\n  :alt: Submission spreadsheet Library screenshot\n\n|\n\n\n\nTo link two items together, simply grab the identifier for the item you are linking to and copy it into the corresponding cell in the spreadsheet. In the example below, the Library item is linking to an Analyte item in the same workbook using its ``submitted_id`` and is linking to an assay on the data portal using its ``identifier``.\n\n|\n\n.. image:: /static/img/docs/link_to_example_diagram.jpg\n  :alt: Linking example diagram\n\n|\n\n\n\nFinding the correct IDs to submit\n---------------------------------\nLinkTo property values must uniquely identify an object, either through a ``submitted_id`` value from another row and/or sheet in the submission workbook or an identifying property for an existing object on the portal (which could also be a ``submitted_id``).\n\n\nFor objects or rows in your workbook\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nWhen linking items that are already on your submission workbook in another row and/or sheet, please use the ``submitted_id`` value as the unique identifier for that item. Refer to the image above with the link from Library to Analyte to see an example of this.\n\n\nFor objects already on the data portal\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nTo find an existing identifier on the portal, please use the links provided below. Each link will bring you to a table with all available items of that given item type. The \u201cSubmitted ID\u201d and \u201cIdentifier\u201d columns serve as unique identifiers for that item, either of which can be used as a LinkTo property value.\n\nThe links to the different reference tables can also be found right from the submission spreadsheet itself:\n\n|\n\n.. image:: /static/img/docs/submitr_spreadsheet_item_dropdown_example.jpg\n  :alt: Linking example diagram\n\n|\n\n.. NOTE::\n  You need to be logged in to the SMaHT data portal in order to see the data at the provided links.\n\n|\n\n\nLinks to data tables to find identifiers on the portal\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n.. raw:: html\n\n    <hr />\n    <div class=\"table-responsive\"> \n        <table class=\"table table-borderless table-sm text-start\" style=\"min-width: 340px;\">\n            <thead class=\"thead-smaht\">\n                <tr class=\"\">\n                    <th class=\"px-2\">Data Type</th>\n                    <th class=\"px-2\">LinkTo Property Options</th>\n                </tr>\n            </thead>\n            <tbody class=\"table-border-inner\">\n                <tr class=\"\">\n                    <td class=\"px-2 d-flex flex-column\">\n                        <a href=\"/search/?type=Donor\">\n                            <b>Donors</b>\n                        </a>\n                        <a href=\"/search/?type=Tissue\">\n                            <b>Tissues</b>\n                        </a>\n                        <a href=\"/search/?type=CellCulture\">\n                            <b>CellCultures</b>\n                        </a>\n                        <a href=\"/search/?type=PreparationKit\">\n                            <b>PreparationKit</b>\n                        </a>\n                        <a href=\"/search/?type=Treatment\">\n                            <b>Treatment</b>\n                        </a>\n                        <a href=\"/search/?type=LibraryPreparation\">\n                            <b>LibraryPreparation</b>\n                        </a>\n                        <a href=\"/search/?type=AnalytePreparation\">\n                            <b>AnalytePreparation</b>\n                        </a>\n                        <a href=\"/search/?type=DonorSpecificAssembly\">\n                            <b>DonorSpecificAssembly</b>\n                        </a>\n                        <a href=\"/search/?type=Software\">\n                            <b>Software</b>\n                        </a>\n                    </td>\n                    <td class=\"px-2\">\n                        Submitted ID\n                    </td>\n                </tr>\n                <tr class=\"\">\n                    <td class=\"px-2 d-flex flex-column\">\n                        <a href=\"/search/?type=Sequencer\">\n                           <b>Sequencers</b>\n                        </a>\n                        <a href=\"/search/?type=Assay\">\n                           <b>Assays</b>\n                        </a>\n                        <a href=\"/search/?type=ReferenceGenome\">\n                           <b>ReferenceGenomes</b>\n                        </a>\n                        <b>FileFormats</b>\n                        <ul class=\"mt-0\">\n                           <li>For <a href=\"/search/?type=FileFormat&valid_item_types=UnalignedReads\">UnalignedReads</a></li>\n                           <li>For <a href=\"/search/?type=FileFormat&valid_item_types=AlignedReads\">AlignedReads</a></li>\n                           <li>For <a href=\"/search/?type=FileFormat&valid_item_types=VariantCalls\">VariantCalls</a></li>\n                           <li>For <a href=\"/search/?type=FileFormat&valid_item_types=SupplementaryFile\">SupplementaryFile</a></li>\n                        </ul>\n                    </td>\n                    <td class=\"px-2\">\n                        Identifier\n                    </td>\n                </tr>\n            </tbody>\n        </table>\n    </div>\n\n\n.. NOTE::\n  The ``smaht-submitr`` tool and SMaHT data portal will automatically ensure that the referenced objects actually exist within SMaHT data portal or are defined within the spreadsheet itself; if this is not the case, an error will be returned.\n\n\n\nOverview of the data model\n--------------------------\nAs mentioned previously, metadata in the portal is connected by linking objects of a variety of item types together. A simplified version of the data model is shown below, with items linking together to indicate how files were derived from experiments, samples, and donors. This structure allows for clear interpretation of the origin of sequence data.\n\n|\n\n.. image:: /static/img/docs/data_model.png\n  :alt: Data Model", "filetype": "rst"}], "consortia": [{"status": "open", "@type": ["Consortium", "Item"], "@id": "/consortia/358aed10-9b9d-4e26-ab84-4bd162da182b/", "uuid": "358aed10-9b9d-4e26-ab84-4bd162da182b", "display_title": "SMaHT", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "identifier": "docs/submission/links-to-existing-data", "date_created": "2024-05-29T01:43:13.801792+00:00", "last_modified": {"modified_by": {"error": "no view permissions"}, "date_modified": "2026-03-28T15:49:10.041184+00:00"}, "schema_version": "1", "table-of-contents": {"enabled": true, "skip-depth": 1, "header-depth": 4, "include-top-link": false}, "submission_centers": [{"uuid": "9626d82e-8110-4213-ac75-0a50adf890ff", "@type": ["SubmissionCenter", "Item"], "display_title": "HMS DAC", "@id": "/submission-centers/9626d82e-8110-4213-ac75-0a50adf890ff/", "status": "open", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "@id": "/docs/submission/links-to-existing-data", "@type": ["DocsSubmissionLinks-to-existing-dataPage", "DocsSubmissionPage", "DocsPage", "StaticPage", "Portal"], "uuid": "1a2da742-acc2-44e2-b5d9-249fe3e837e1", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}, "display_title": "Linking Metadata During Submission", "@context": "/docs/submission/links-to-existing-data", "is_leaf": true, "toc": {"enabled": true, "skip-depth": 1, "header-depth": 4, "include-top-link": false}, "next": {"identifier": "docs/submission/uploading-files", "title": "Uploading Files", "status": "open", "content": [{"display_title": "uploading_files", "uuid": "1a2fdcbf-eead-4441-a028-76c5a3e2ac16", "@type": ["StaticSection", "UserContent", "Item"], "@id": "/static-sections/1a2fdcbf-eead-4441-a028-76c5a3e2ac16/", "status": "open", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "consortia": [{"@type": ["Consortium", "Item"], "@id": "/consortia/358aed10-9b9d-4e26-ab84-4bd162da182b/", "display_title": "SMaHT", "status": "open", "uuid": "358aed10-9b9d-4e26-ab84-4bd162da182b", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "date_created": "2024-05-29T01:43:13.922809+00:00", "last_modified": {"modified_by": {"error": "no view permissions"}, "date_modified": "2026-03-28T15:49:10.142153+00:00"}, "schema_version": "1", "table-of-contents": {"enabled": true, "skip-depth": 1, "header-depth": 4, "include-top-link": false}, "submission_centers": [{"@id": "/submission-centers/9626d82e-8110-4213-ac75-0a50adf890ff/", "status": "open", "@type": ["SubmissionCenter", "Item"], "display_title": "HMS DAC", "uuid": "9626d82e-8110-4213-ac75-0a50adf890ff", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "@id": "/docs/submission/uploading-files", "@type": ["DocsSubmissionUploading-filesPage", "DocsSubmissionPage", "DocsPage", "StaticPage", "Portal"], "uuid": "2a3b8679-16a7-44be-8676-e4c290bef36e", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}, "display_title": "Uploading Files", "is_leaf": true, "sibling_length": 3, "sibling_position": 2}, "previous": {"identifier": "docs/submission/getting-started-with-submissions", "title": "Getting Started with Submissions", "status": "open", "content": [{"display_title": "getting_started", "uuid": "442c8aa0-dc6c-43d7-814a-854af460b015", "@type": ["StaticSection", "UserContent", "Item"], "@id": "/static-sections/442c8aa0-dc6c-43d7-814a-854af460b015/", "status": "open", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "consortia": [{"@type": ["Consortium", "Item"], "@id": "/consortia/358aed10-9b9d-4e26-ab84-4bd162da182b/", "display_title": "SMaHT", "status": "open", "uuid": "358aed10-9b9d-4e26-ab84-4bd162da182b", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "date_created": "2024-05-29T01:43:13.674722+00:00", "last_modified": {"modified_by": {"error": "no view permissions"}, "date_modified": "2026-03-28T15:49:09.951685+00:00"}, "schema_version": "1", "table-of-contents": {"enabled": true, "skip-depth": 1, "header-depth": 4, "include-top-link": false}, "submission_centers": [{"@id": "/submission-centers/9626d82e-8110-4213-ac75-0a50adf890ff/", "status": "open", "@type": ["SubmissionCenter", "Item"], "display_title": "HMS DAC", "uuid": "9626d82e-8110-4213-ac75-0a50adf890ff", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "@id": "/docs/submission/getting-started-with-submissions", "@type": ["DocsSubmissionGetting-started-with-submissionsPage", "DocsSubmissionPage", "DocsPage", "StaticPage", "Portal"], "uuid": "dad6eb69-bdd0-4409-898a-6e95ba420bc0", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}, "display_title": "Getting Started with Submissions", "is_leaf": true, "sibling_length": 3, "sibling_position": 0}, "parent": {"identifier": "docs/submission", "parent": {"identifier": "docs", "parent": {"identifier": "", "@id": "/", "display_title": "Home", "@type": ["DirectoryPage", "StaticPage", "Portal"]}, "@id": "/docs", "uuid": "089319c4-3ce9-4ec1-bd0b-5451a48bd99e", "display_title": "Documentation", "@type": ["DocsPage", "DirectoryPage", "StaticPage", "Portal"], "sibling_length": 5, "sibling_position": 3}, "title": "Submission", "status": "open", "consortia": [{"@id": "/consortia/358aed10-9b9d-4e26-ab84-4bd162da182b/", "status": "open", "uuid": "358aed10-9b9d-4e26-ab84-4bd162da182b", "@type": ["Consortium", "Item"], "display_title": "SMaHT", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "date_created": "2024-05-29T01:43:13.395136+00:00", "last_modified": {"modified_by": {"error": "no view permissions"}, "date_modified": "2026-03-28T15:49:09.757339+00:00"}, "schema_version": "1", "table-of-contents": {"enabled": true, "skip-depth": 1, "header-depth": 4, "include-top-link": false}, "submission_centers": [{"uuid": "9626d82e-8110-4213-ac75-0a50adf890ff", "display_title": "HMS DAC", "@id": "/submission-centers/9626d82e-8110-4213-ac75-0a50adf890ff/", "status": "open", "@type": ["SubmissionCenter", "Item"], "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}}], "@id": "/docs/submission", "@type": ["DocsSubmissionPage", "DocsPage", "DirectoryPage", "StaticPage", "Portal"], "uuid": "6523af8e-34e5-40eb-9e09-710a41b824a4", "principals_allowed": {"view": ["system.Everyone"], "edit": ["group.admin"]}, "display_title": "Submission", "sibling_length": 3, "sibling_position": 1}, "sibling_length": 3, "sibling_position": 1}