Skip to content

Sequencing Assay Setup - #113

Open
awarkow wants to merge 7 commits into
mainfrom
sequencing-assays
Open

awarkow wants to merge 7 commits into
mainfrom
sequencing-assays

Conversation

@awarkow

@awarkow awarkow commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Summary

This PR adresses #89 by adding sequencing-specific assay classes to the Common Access Model. They extend the existing generic Assay class so we can capture experiment metadata for whole genome, whole exome and RNA sequencing data.

New Assay Classes

The new classes form a hierarchy under the existing Assay class:
Assay
└── SequencingAssay
├── GenomicsAssay (WGS/WXS)
└── TranscriptomicsAssay (RNA-Seq)

Each subclass inherits all slots from its parent. Every sequencing assay therefore keeps the core Assay fields (assay_id, subject_id, sample_id, file_id, assay_type, etc.) and adds its own experiment metadata.

SequencingAssay

Sequencing Experiment Assay: a sequencing experiment performed on a Biospecimen. This is the shared base for all sequencing assays.

Slot Range Description
sequencing_center_id The sequencing center that performed the experiment
library_name string Name of the sequencing library
experiment_date date Date the sequencing experiment was performed
experiment_strategy EnumSequencingStrategy Sequencing strategy used
is_paired_end boolean Whether reads are paired-end
platform EnumSequencingPlatform Sequencing platform used
instrument_model EnumSequencingInstrument Sequencing instrument model used
total_reads integer Total number of reads generated
is_adapter_trimmed boolean Whether adapter sequences were trimmed
adapter_sequencing string Adapter sequence used, if known (expected when is_adapter_trimmed is false)
quality_scale EnumReadGroupQualityScale Quality score scale used for the read group
reference_genome EnumReferenceGenome Reference genome build the data was aligned to or generated against
workflow_type string Type of workflow that produced the file (Kids First Dataservice: workflow_type)
workflow_tool string Tool used by the workflow (Kids First Dataservice: workflow_tool)
workflow_version string Version of the workflow tool
workflow_endpoint Workflow endpoint
flow_cell string Flow cell identifier for the read group
lane_number integer Lane number for the read group

GenomicsAssay

WGS/WXS Assay: a whole genome or whole exome sequencing experiment performed on a Biospecimen. It extends SequencingAssay with alignment and coverage metrics.

Slot Range Description
max_insert_size integer Maximum insert size (bp)
mean_insert_size float Mean insert size (bp)
mean_depth float Mean sequencing depth of coverage
mean_read_length integer Mean read length (bp)
target_capture_kit string Target capture kit used, if any (relevant for WXS)

TranscriptomicsAssay

RNA Sequencing Assay: an RNA sequencing experiment performed on a Biospecimen. It extends SequencingAssay with library construction details.

Slot Range Description
library_strand EnumLibraryStrand Strandedness of the sequencing library
library_prep EnumLibraryPrep Library preparation method
library_selection EnumLibrarySelection Library selection method

New Enums

Caution

Work in progress. The new slots reference several enums. Only the 3 below are defined so far. Need to pair others with correct ontologies

EnumLibraryPrep

Library preparation methods for RNA sequencing. Values are drawn from OBI and constrained to subclasses of an OBI source node.

Value Title Description
OBI:0000848 polyA RNA extraction An RNA extraction process, typically using poly dT oligomers, whose desired output material is polyA RNA.
OBI:0000855 total RNA depletion An RNA extraction process in which total cellular and organelle RNA are extracted.

EnumAnalyteType

The type of analyte extracted from the biospecimen. Values are drawn from NCIt and constrained to subclasses of NCIt C706.

Value Title Description
C449 DNA A long linear double-stranded polymer formed from nucleotides attached to a deoxyribose backbone and found in the nucleus of a cell; associated with the transmission of genetic information.
C812 RNA Single-stranded long chain of nucleotides containing ribose.

EnumLibrarySelection

Library selection methods used to enrich or select nucleic acid for sequencing. Values are drawn from NCIt and constrained to subclasses of NCIt C15241.

Value Title Description
C163986 Hybrid Selection A genomic library where the sample has been subjected to enrichment via nucleic acid hybridization.
C17003 PCR A method for amplifying a DNA base sequence using multiple rounds of heat denaturation of the DNA and annealing of oligonucleotide primers complementary to flanking regions in the presence of a heat-stable polymerase.
C163987 Affinity Enrichment A genomic library where the sample has been subjected to enrichment via binding to a target protein or oligonucleotide prior to molecular analysis.
C163988 Poly-T Enrichment A genomic library where the sample has been subjected to enrichment via binding to immobilized poly-T oligonucleotides, which will preferentially isolate polyadenylated (poly-A) RNAs.
C163989 Random A genomic library constructed to generate random DNA fragments by subjecting a genomic sample to either amplification using random primers or fragmentation via exposure to restriction enzymes or shear stress.
C163990 rRNA Depletion A genomic library where the sample has been subjected to a ribosomal RNA depletion step before it is amplified.
C163991 miRNA Size Fractionation A RNA library that has been fractionated by size exclusion methods to enrich for microRNAs.

Open Questions

  • Is library_prep the same thing as library_construction? If so, should we rename or alias it?
  • Should adapter_sequencing be conditionally required when is_adapter_trimmed is false? Can we enforce this with a LinkML rule?

@awarkow awarkow changed the title Sequencing Assay Setup 🚧 Sequencing Assay Setup Oct 19, 2026
@awarkow
awarkow marked this pull request as draft October 19, 2026 14:45
@github-actions

github-actions Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor
PR Preview Action v1.8.1

QR code for preview link

🚀 View preview at
https://include-dcc.github.io/common-access-model/pr-preview/pr-113/

Built to branch gh-pages at 2026-11-05 18:30 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@torstees @yelenacox I used term-weaver to generate this enum (its a small subset but I wanted to test it out). The values are here in OLS and I was able to expand using weaver but for some reason the formatting is off. The values should be in the format ILLUMINA_1_3 but are appearing as ILLUMINA_1:3.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for flagging this. We've been reviewing it. There's some "bad"/"probably unintended" behavior within OLS. We've been using the obo_id field as its' typically a nicely formatted CURIE, but for non-OBOs it is interpreting the _ as part of the OBO id, turning it (incorrectly) into a curie.
https://obofoundry.org/id-policy.html

FOUNDRY_OBO_URI ::= "http://purl.obolibrary.org/obo/" IDSPACE "_" LOCALID

There's not a consistent way to pull the data via API, but we have some ideas about solutions.

@awarkow

awarkow commented Oct 29, 2026

Copy link
Copy Markdown
Contributor Author

🚧 Enums still in progress but need review

Paired to ontologies

  • EnumAnalyteType -> OBI
  • EnumLibraryPrep -> OBI
  • EnumLibrarySelection -> NCI
  • EnumLibraryStrand -> NCI
  • EnumReadGroupQualityScale -> ValueSets

Still to pair

  • EnumSequencingInstrument
  • EnumSequencingCenter
  • EnumSequencingPlatform
  • EnumSequencingStrategy
  • EnumReferenceGenome

@awarkow
awarkow marked this pull request as ready for review October 29, 2026 17:43
@awarkow awarkow changed the title 🚧 Sequencing Assay Setup Sequencing Assay Setup Oct 29, 2026
@RobertJCarroll

Copy link
Copy Markdown
Collaborator

I started to look over the enums. I think it might be helpful if we documented some better conventions / easy paths to leveraging the tools as I can tell some things are unclear.

  • The enumerated values should include the curie prefix, eg, ncit:C163986 not just C163986. This goes for the meaning as well.
  • You only need reachable_from if you plan to use the integrated expansion. If you want to define it all "by hand", you can skip that field/section.
  • You can "cheat" a little and get term weaver to do some heavy lifting. I see that a lot of these NCIt hierarchy sections aren't well specified / don't line up with your enums, but there are a few approaches to take that might speed up the process:
  1. Pick a rough parent code in the reachable_from, run term-weaver, then manually prune the results and remove the reachable_from.
  2. Pick a rough parent code in the reachable_from, add the minus list for things you don't want, then run term weaver. Minus is described on this page. You could also run term weaver with the rough parent, then pull the things you don't want into the minus list from that.
  3. You can also just add all of your terms to source_nodes and make sure include_self: true. This will expand everything you included so you don't have to manually get the titles/descriptions. You can either clean up the reachable_from at that point or leave it in- just depends on if you "like" the query as it might add more terms if re-run in the future.

I'll work up some examples as I'm sure it would be helpful for any potential contributor.

@RobertJCarroll

RobertJCarroll commented Oct 30, 2026 •

Copy link
Copy Markdown
Collaborator

I took a look at EnumLibrarySelection. You can seed with:

---
id: https://includedcc.org/common-access-model/EnumLibrarySelection
name: EnumLibrarySelection
enums:
  EnumLibrarySelection:
    description: null
    reachable_from:
      source_ontology: bioregistry:ncit
      source_nodes:
        - NCIT:C15241
      include_self: false
      is_direct: false
      relationship_types:
        - rdfs:subClassOf

Which will grab everything but PCR. You could then add it in manually. If you did, I'd recommend making some note about the changes you made to help prevent future issues if someone wanted to regenerate. (edit: We could also discuss some potential additional features / options here?)

I'm a little suspicious of that PCR term though- how is that one distinct from the others?

@RobertJCarroll

Copy link
Copy Markdown
Collaborator

OLS seems to be struggling, but let me know if it'd be helpful to dig into these more. It should make writing the enums easier / cleaner!

@RobertJCarroll

Copy link
Copy Markdown
Collaborator

@awarkow We've been investigating the Valuesets "ontology"- turns out it's a collection of enumerations. While it is loaded into a few places, it's wonky in OLS. We're putting a bug report in to them about it, but we are also wondering how attached you are to using that list. Is there an underlying set of terms you all are using that we could leverage or are these the right ones? We are considering creating terms given the odd API behaviors.

@awarkow

awarkow commented Nov 3, 2026

Copy link
Copy Markdown
Contributor Author

Summary of Added Enums

For review by Kids First BIX team: @yuankunzhu

Maps the sequencing-related constants from kf_lib_data_ingest/common/constants.py onto ontology-backed enums.

8/10 enums added in src/common_access_model/schema/enums/ are mapped. 2 still need discussion. Summarized here:

Enum Source constant Ontology
EnumSequencingPlatform SEQUENCING.PLATFORM NCIT
EnumSequencingInstrument SEQUENCING.INSTRUMENT OBI
EnumSequencingStrategy SEQUENCING.STRATEGY NCIT
EnumLibraryStrand SEQUENCING.STRAND NCIT
EnumLibrarySelection SEQUENCING.LIBRARY.SELECTION NCIT
EnumLibraryPrep SEQUENCING.LIBRARY.PREP OBI, NCIT
EnumAnalyteType SEQUENCING.ANALYTE SNOMED CT
EnumReferenceGenome SEQUENCING.REFERENCE_GENOME LOINC
--- --- ---
EnumSequencingCenter SEQUENCING.CENTER CAMO?
EnumReadGroupQualityScale READ_GROUP.QUALITY_SCALE ValueSets

Mappings

EnumSequencingPlatform

Original value Mapped to Code
Complete Genomics Complete Genomics Sequencing NCIT:C146815
SOLiD ABI SOLiD Sequencing NCIT:C146811
Illumina Illumina Sequencing NCIT:C146817
LS454 454 Sequencing NCIT:C146809
ONT Nanopore Sequencing NCIT:C146818
PacBio SMRT Sequencing NCIT:C146819
Ion Torrent Ion Semiconductor Sequencing NCIT:C125894

Added a reachable_from block (NCIT) listing these seven nodes with include_self: true.

EnumSequencingInstrument

Original value Mapped to Code
HiSeq X Ten Illumina HiSeq X Ten OBI:0002129
HiSeq X v2.5 not mapped (no matching OBI term found) n/a

I also added the other Illumina HiSeq models found under OBI OBI:0003683, which are not in the original constants:
HiSeq 1000 (OBI:0002022), 1500 (OBI:0003386), 2000 (OBI:0002001), 2500 (OBI:0002002), 3000 (OBI:0002048), 4000 (OBI:0002049).
Added a reachable_from block rooted at OBI:0003683.

EnumSequencingStrategy

Original value Mapped to Code
WGS Whole Genome Sequencing NCIT:C101294
WXS Whole Exome Sequencing NCIT:C101295
RNA-Seq RNA Sequence Analysis NCIT:C192768
miRNA-Seq (MRNA) mRNA Sequencing and MicroRNA Sequencing NCIT:C129432, NCIT:C156057
scRNA-Seq Single Cell RNA Sequencing NCIT:C171152
Panel Tumor Panel Sequencing NCIT:C165600
Disease Panel Gene Sequencing NCIT:C173599
Multi-gene Panel Sequencing NCIT:C198412
Targeted Sequencing Targeted Capture Sequencing NCIT:C204828
Targeted Genome Sequencing NCIT:C158253
Targeted Transcriptome Sequencing NCIT:C158252
Methylation Methyl-binding Domain Sequencing NCIT:C204820
Methylated DNA Immunoprecipitation Sequencing NCIT:C204821
Methylation-Sensitive Restriction Enzyme Sequencing NCIT:C204822
Proteomics Proteomics NCIT:C20085
ONT WGS Oxford Nanopore Sequencing NCIT:C146818
CCS WGS, CLR WGS Long Read Sequencing (one code covers both) NCIT:C223895

No mapping yet (left as placeholder comments in the YAML): Linked-Read WGS (10x), snRNA-Seq, CCS RNA-Seq, CLR RNA-Seq.

EnumLibraryStrand

Original value Mapped to Code
Unstranded Unstranded Library Sequencing NCIT:C150427
First Stranded First-strand Library Sequencing NCIT:C150428
Second Stranded Second-strand Library Sequencing NCIT:C150426
Stranded not mapped (generic term, no matching code) n/a

EnumLibrarySelection

Original value Mapped to Code
Hybrid Selection Hybrid Selected Genomic Library NCIT:C163986
Affinity Enrichment Affinity Enriched Genomic Library NCIT:C163987
Poly-T Enrichment Poly-A Enriched Genomic Library NCIT:C163988
Random Randomly Selected Genomic Library NCIT:C163989
rRNA Depletion rRNA Depleted Genomic Library NCIT:C163990
miRNA Size Fractionation miRNA Size Fractionated Genomic Library NCIT:C163991
PCR Polymerase Chain Reaction NCIT:C17003

EnumLibraryPrep

Original value Mapped to Code
polyA polyA RNA extraction OBI:0000848
Poly-A Enriched Genomic Library NCIT:C163988
totalRNAseq total RNA depletion OBI:0000855
rRNA Depleted Genomic Library NCIT:C163990

EnumAnalyteType

Original value Mapped to Code
DNA DNA SNOMEDCT:24851008
RNA RNA SNOMEDCT:27888000
Virtual not mapped n/a

EnumReferenceGenome

Original value Code
GRCh37 loinc:LA14029-5
GRCh38 loinc:LA26806-2
hg19 loinc:LA14025-3
hs37d5 commented out (no code found)

Questions for reviewers

  1. MRNA = "miRNA-Seq" upstream. The constant name says mRNA but the value says miRNA, so I mapped it to both NCIT:C129432 (mRNA) and NCIT:C156057 (microRNA). Should one of these be dropped?
  2. One-to-many strategy mappings. Methylation, Targeted and Panel each map to several NCIT terms. Is only one of these correct or should all be included as potential values?
  3. Long-read strategies. CCS WGS and CLR WGS collapse to one Long Read Sequencing code, so the CCS/CLR distinction is lost. The RNA variants are unmapped since the description mentions sequencing of DNA. Additional values may be needed in CAMO.
  4. Unmapped values. HiSeq X v2.5, Virtual, hs37d5, Linked-Read WGS, snRNA-Seq, CCS RNA and CLR RNA have no code yet. Suggestions welcome.
  5. EnumLibraryPrep overlaps with EnumLibrarySelection. NCIT:C163988 and NCIT:C163990 appear in both enums. Is that correct?
  6. NCIT:C146818 in two enums. It is the platform "Nanopore Sequencing" in EnumSequencingPlatform and "Oxford Nanopore Sequencing" in EnumSequencingStrategy, so the same code is used for ONT WGS. Is this okay?

@awarkow

awarkow commented Nov 3, 2026

Copy link
Copy Markdown
Contributor Author

@RobertJCarroll That list (ValueSets/SequenceQualityEncoding) contains the exact 5 values we need to add for this enum. I thought it had potential to use since it does match exactly with our preferred terms, but I'm okay with adding to CAMO if the formatting in OLS is messing things up

@RobertJCarroll

Copy link
Copy Markdown
Collaborator

This is where we are talking with the OLS team as an fyi: EBISPOT/ols4#1484

@yuankunzhu

yuankunzhu commented Nov 13, 2026 •

Copy link
Copy Markdown

@awarkow for the questions you have

  • MRNA = "miRNA-Seq" upstream. The constant name says mRNA but the value says miRNA, so I mapped it to both NCIT:C129432 (mRNA) and NCIT:C156057 (microRNA). Should one of these be dropped?

    • drop the mRNA code, the value in the data is "miRNA-Seq" which means the microRNA, so we should just map it to NCIT:C156057
  • One-to-many strategy mappings. Methylation, Targeted and Panel each map to several NCIT terms. Is only one of these correct or should all be included as potential values?

    • Panel: we should use NCIT:C198412 Multi-gene Panel Sequencing, to be more general, it's the parent of of both Tumor Panel and Disease Panel
    • Targeted Sequencing: we typically don't have Targeted Transcriptome Sequencing, and the "Targeted Genome Sequencing" is the parent of "Targeted Capture Sequencing", so I suggest we go with the parent term
      "Targeted Genome Sequencing | NCIT:C158253"
    • Methylation: for now, we have only had array based methylation data, so all three listed terms are wrong, we should use NCIT:C165222 DNA Methylation Array
  • Long-read strategies. CCS WGS and CLR WGS collapse to one Long Read Sequencing code, so the CCS/CLR distinction is lost. The RNA variants are unmapped since the description mentions sequencing of DNA. Additional values may be needed in CAMO.

    • CCS and CLR are the different sequencing mode for PacBio as pose to a "Sequencing Strategy"
    • also noticed we listed "ONT WGS" as "Oxford Nanopore Sequencing" under "Sequencing Strategy", which could also be miss-leading, because Nanopore can be used for WGS, RNA-seq (including direct RNA), targeted panels and so on
    • I will suggeset the following:
      • add "CCS" and "CLS" as a enum values for "sequencing_mode" in CAMO and then apply the following
      • ONT WGS: strategy C101294 (WGS) + platform C146818 (Nanopore)
      • CCS WGS: strategy C101294 (WGS) + platform C146818 (PacBio) + sequencing_mode (CCS)
      • CLR WGS: strategy C101294 (WGS) + platform C146819 (PacBio) + sequencing_mode (CLS)
      • i think this should also address your last question on "NCIT:C146818 in two enums"
        Happy to discuss more about this.
  • EnumLibraryPrep overlaps with EnumLibrarySelection. NCIT:C163988 and NCIT:C163990 appear in both enums. Is that correct?

    • keep LibraryPrep OBI-only (polyA as OBI:0000848, and totalRNAseq as OBI:0000855) and keep the NCIt library terms in LibrarySelection. C124261 should come out of LibraryPrep, because it’s a strategy term.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants