id: https://w3id.org/ber-data/gff-feature-model/flat
name: ber-feature-model-flat
title: BER feature model, flat scalar-only profile
description: Generated by scripts/flat_profile.py from model/schema/ber_feature_model.yaml; do not edit.
  The nested model is canonical.
license: https://creativecommons.org/publicdomain/zero/1.0/
prefixes:
  linkml: https://w3id.org/linkml/
  bfmflat: https://w3id.org/ber-data/gff-feature-model/flat/
default_prefix: bfmflat
default_range: string
imports:
- linkml:types
classes:
  ContigCollection:
    description: One ContigCollection; derived from the nested model.
    attributes:
      collection_id:
        range: string
        description: Identifier of the genome, bin or assembly, from the system that defined it.
        required: true
        identifier: true
      collection_type:
        range: ContigCollectionTypeEnum
        description: What kind of contig collection this is.
      name:
        range: string
        description: 'Human-readable name, not an identifier and not unique: for a contig collection an
          organism and strain or a bin label; for a feature the GFF3 Name, its display name.'
      generated_by:
        range: string
        description: The workflow execution (or tool run) that produced this ContigCollection, Contig
          or SequenceFeature.
  ContigCollectionTaxonomicLineage:
    description: ContigCollection.taxonomic_lineage, one row per item.
    attributes:
      collection_id:
        range: string
        required: true
        description: The collection_id of the contig_collection row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in ContigCollection.taxonomic_lineage, from 0.
      taxonomic_lineage:
        range: string
        description: Ranked lineage path, domain to strain, one string per rank.
        required: true
  ContigCollectionSourceFiles:
    description: ContigCollection.source_files, one row per item.
    attributes:
      collection_id:
        range: string
        required: true
        description: The collection_id of the contig_collection row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in ContigCollection.source_files, from 0.
      source_files:
        range: uri
        description: Source artifact URLs supporting this record, including any annotation sidecars used.
        required: true
  Contig:
    description: One Contig; derived from the nested model.
    attributes:
      contig_id:
        range: string
        description: Native NMDC or source-system identifier for the contig or scaffold.
        required: true
        identifier: true
      length_bp:
        range: integer
        minimum_value: 1
        description: Contig length in base pairs.
      topology:
        range: TopologyEnum
        description: Declared reference topology; circular locations also require length_bp.
      translation_table:
        range: integer
        minimum_value: 1
        maximum_value: 33
        description: NCBI genetic code used to translate coding features on this contig, such as 11 for
          bacteria and archaea or 4 for Mycoplasma.
      lineage_confidence:
        range: float
        description: Confidence value reported alongside the lineage call.
      generated_by:
        range: string
        description: The workflow execution (or tool run) that produced this ContigCollection, Contig
          or SequenceFeature.
  ContigMemberOf:
    description: Contig.member_of, one row per item.
    attributes:
      contig_id:
        range: string
        required: true
        description: The contig_id of the contig row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in Contig.member_of, from 0.
      member_of:
        range: string
        description: The collection_id of a contig_collection row.
        required: true
  ContigTaxonomicLineage:
    description: Contig.taxonomic_lineage, one row per item.
    attributes:
      contig_id:
        range: string
        required: true
        description: The contig_id of the contig row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in Contig.taxonomic_lineage, from 0.
      taxonomic_lineage:
        range: string
        description: Ranked lineage path, domain to strain, one string per rank.
        required: true
  ContigSourceFiles:
    description: Contig.source_files, one row per item.
    attributes:
      contig_id:
        range: string
        required: true
        description: The contig_id of the contig row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in Contig.source_files, from 0.
      source_files:
        range: uri
        description: Source artifact URLs supporting this record, including any annotation sidecars used.
        required: true
  SequenceFeature:
    description: One SequenceFeature; derived from the nested model.
    attributes:
      feature_id:
        range: string
        description: Identity unique within this Dataset; supplied by the source or assigned by an explicit
          profile.
        required: true
        identifier: true
      seqid:
        range: string
        description: The reference sequence that start and end are measured along, such as GFF3 column
          1 or BED chrom; interpreted within its assembly context. A contig for contig coordinates; for
          protein coordinates, the CDS whose translation they count residues of.
        required: true
      source:
        range: string
        description: GFF3 column 2, the producing tool and version, e.g. "Prodigal v2.6.3_patched".
      type:
        range: string
        description: GFF3 column 3, nominally a Sequence Ontology term or accession.
      method:
        range: MethodEnum
        description: The annotation method or reference database whose search produced this feature, such
          as Pfam or KEGG Orthology.
      start:
        range: integer
        minimum_value: 1
        description: 1-based inclusive start; when location is present this is only the minimum reported
          part coordinate, not a claim that gaps are occupied.
        required: true
      end:
        range: integer
        minimum_value: 1
        description: 1-based inclusive end, always >= start; when location is present this is only the
          maximum reported part coordinate.
        required: true
      coordinate_system:
        range: CoordinateSystemEnum
        description: Which coordinate space `start`/`end` are measured in.
        required: true
      score:
        range: float
        description: GFF3 column 6.
      score_type:
        range: ScoreTypeEnum
        description: What kind of number score is.
      strand:
        range: StrandEnum
        description: GFF3 column 7.
      phase:
        range: integer
        minimum_value: 0
        maximum_value: 2
        description: GFF3 column 8. One of 0, 1, 2; only meaningful when type is CDS.
      generated_by:
        range: string
        description: The workflow execution (or tool run) that produced this ContigCollection, Contig
          or SequenceFeature.
      is_selected:
        range: boolean
        description: Whether the annotation pipeline chose this call as canonical for its locus.
      is_representative:
        range: boolean
        description: Whether the source names this transcript as its gene's representative isoform, the
          one to use when a query wants a single transcript per gene.
      product:
        range: string
        description: Human-readable functional product name for a gene, e.g. "transposase".
      product_source:
        range: string
        description: What justified the product call, e.g. a COG accession or "Hypo-rule applied".
      name:
        range: string
        description: 'Human-readable name, not an identifier and not unique: for a contig collection an
          organism and strain or a bin label; for a feature the GFF3 Name, its display name.'
      translated_sequence:
        range: string
        description: Amino-acid translation of a CDS feature, from the workflow's protein FASTA output.
      location_operator:
        range: LocationOperatorEnum
        description: Whether the parts describe one interval, a joined sequence, or ordered intervals
          without a join assertion.
      location_crosses_origin:
        range: boolean
        description: True only when traversal crosses the origin of a known-length circular reference.
      target_id:
        range: string
        description: What the hit aligned to, as the source names it, such as a Pfam accession or a reference
          gene ID.
      target_start:
        range: integer
        minimum_value: 1
        description: First aligned position on the target, one-based and inclusive.
      target_end:
        range: integer
        minimum_value: 1
        description: Last aligned position on the target, one-based and inclusive.
      target_strand:
        range: StrandEnum
        description: Strand of the alignment on the target, when the target is a nucleotide sequence.
      target_gap:
        range: string
        description: The alignment in GFF3 Gap form, a CIGAR-like string of operations and lengths.
    rules:
    - preconditions:
        slot_conditions:
          score_type:
            value_presence: PRESENT
      postconditions:
        slot_conditions:
          score:
            value_presence: PRESENT
      description: A score_type qualifies a score, so it needs one (issue 46).
    - description: location is present once location_operator is, so it needs location_crosses_origin.
      preconditions:
        slot_conditions:
          location_operator:
            value_presence: PRESENT
      postconditions:
        slot_conditions:
          location_crosses_origin:
            value_presence: PRESENT
    - description: location is present once location_crosses_origin is, so it needs location_operator.
      preconditions:
        slot_conditions:
          location_crosses_origin:
            value_presence: PRESENT
      postconditions:
        slot_conditions:
          location_operator:
            value_presence: PRESENT
    - description: target is present once target_id is, so it needs target_start, target_end.
      preconditions:
        slot_conditions:
          target_id:
            value_presence: PRESENT
      postconditions:
        slot_conditions:
          target_start:
            value_presence: PRESENT
          target_end:
            value_presence: PRESENT
    - description: target is present once target_start is, so it needs target_id, target_end.
      preconditions:
        slot_conditions:
          target_start:
            value_presence: PRESENT
      postconditions:
        slot_conditions:
          target_id:
            value_presence: PRESENT
          target_end:
            value_presence: PRESENT
    - description: target is present once target_end is, so it needs target_id, target_start.
      preconditions:
        slot_conditions:
          target_end:
            value_presence: PRESENT
      postconditions:
        slot_conditions:
          target_id:
            value_presence: PRESENT
          target_start:
            value_presence: PRESENT
    - description: target is present once target_strand is, so it needs target_id, target_start, target_end.
      preconditions:
        slot_conditions:
          target_strand:
            value_presence: PRESENT
      postconditions:
        slot_conditions:
          target_id:
            value_presence: PRESENT
          target_start:
            value_presence: PRESENT
          target_end:
            value_presence: PRESENT
    - description: target is present once target_gap is, so it needs target_id, target_start, target_end.
      preconditions:
        slot_conditions:
          target_gap:
            value_presence: PRESENT
      postconditions:
        slot_conditions:
          target_id:
            value_presence: PRESENT
          target_start:
            value_presence: PRESENT
          target_end:
            value_presence: PRESENT
  SequenceFeatureStableIdentifiers:
    description: SequenceFeature.stable_identifiers, one row per item.
    attributes:
      feature_id:
        range: string
        required: true
        description: The feature_id of the sequence_feature row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in SequenceFeature.stable_identifiers, from 0.
      stable_identifiers:
        range: string
        description: Identifiers an authority assigns to this feature and keeps across releases, as opposed
          to feature_id, which only needs to be unique within this Dataset.
        required: true
  SequenceFeatureParent:
    description: SequenceFeature.parent, one row per item.
    attributes:
      feature_id:
        range: string
        required: true
        description: The feature_id of the sequence_feature row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in SequenceFeature.parent, from 0.
      parent:
        range: string
        description: The feature_id of a sequence_feature row.
        required: true
  SequenceFeatureAttributes:
    description: SequenceFeature.attributes, one row per item.
    attributes:
      feature_id:
        range: string
        required: true
        description: The feature_id of the sequence_feature row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in SequenceFeature.attributes, from 0.
      key:
        range: string
        description: Source-reported attribute name, unnormalized (for example a GFF tag or metadata key).
        required: true
      value:
        range: string
        description: 'The source''s text for one value, as a string: not typed or normalized, with any
          escapes the source profile defines decoded (a GFF3 %2C is stored as a comma).'
        required: true
      attribute_cv_id:
        range: uriorcurie
        description: A CURIE for what the key means, from an ontology or controlled vocabulary, set by
          a profile that maps this key; for example EDAM:data_1667 (E-value) for both e-value and evalue.
          key keeps the source spelling either way.
      numeric_value:
        range: float
        description: value read as a number, set by a profile only for keys it knows are numeric. value
          keeps the source text, so 3.4e-28 and 3.40E-28 stay distinguishable. The validator requires
          the float that value reads as, and refuses an integer no float holds exactly.
  SequenceFeatureSourceFiles:
    description: SequenceFeature.source_files, one row per item.
    attributes:
      feature_id:
        range: string
        required: true
        description: The feature_id of the sequence_feature row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in SequenceFeature.source_files, from 0.
      source_files:
        range: uri
        description: Source artifact URLs supporting this record, including any annotation sidecars used.
        required: true
  SequenceFeatureNote:
    description: SequenceFeature.note, one row per item.
    attributes:
      feature_id:
        range: string
        required: true
        description: The feature_id of the sequence_feature row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in SequenceFeature.note, from 0.
      note:
        range: string
        description: GFF3 Note values, free-text remarks about the feature, in source order.
        required: true
  SequenceFeatureDbxref:
    description: SequenceFeature.dbxref, one row per item.
    attributes:
      feature_id:
        range: string
        required: true
        description: The feature_id of the sequence_feature row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in SequenceFeature.dbxref, from 0.
      dbxref:
        range: string
        description: GFF3 Dbxref values, db:id references to records in other databases, in source order.
          Unlike stable_identifiers, a cross-reference can point at a related record rather than at this
          feature itself, such as a GeneID on a CDS.
        required: true
  SequenceFeatureOntologyTerm:
    description: SequenceFeature.ontology_term, one row per item.
    attributes:
      feature_id:
        range: string
        required: true
        description: The feature_id of the sequence_feature row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in SequenceFeature.ontology_term, from 0.
      ontology_term:
        range: string
        description: GFF3 Ontology_term values, ontology term CURIEs such as GO:0003677, in source order.
        required: true
  SequenceFeatureLocationParts:
    description: SequenceFeature.location.parts, one row per item.
    attributes:
      feature_id:
        range: string
        required: true
        description: The feature_id of the sequence_feature row this belongs to.
      ordinal:
        range: integer
        required: true
        minimum_value: 0
        description: Position in SequenceFeature.location.parts, from 0.
      seqid:
        range: string
        description: The contig_id of a contig row.
        required: true
      start:
        range: integer
        minimum_value: 1
        description: 1-based inclusive start; when location is present this is only the minimum reported
          part coordinate, not a claim that gaps are occupied.
        required: true
      end:
        range: integer
        minimum_value: 1
        description: 1-based inclusive end, always >= start; when location is present this is only the
          maximum reported part coordinate.
        required: true
      strand:
        range: StrandEnum
        description: GFF3 column 7.
        required: true
      start_status:
        range: EndpointStatusEnum
        description: Exact lower endpoint or a bound before or after the reported coordinate.
        required: true
      end_status:
        range: EndpointStatusEnum
        description: Exact upper endpoint or a bound before or after the reported coordinate.
        required: true
enums:
  ContigCollectionTypeEnum:
    description: Kind of contig collection, using the values and descriptions of KBase CDM ContigCollectionType.
    permissible_values:
      isolate:
        description: Sequences assembled from DNA of isolated organism.
      mag:
        description: Sequences assembled from DNA of mixed community and binned.
      metagenome:
        description: Sequences assembled from DNA of mixed community.
      metatranscriptome:
        description: Sequences assembled from RNA of mixed community.
      sag:
        description: Sequences assembled from DNA of single cell.
      virus:
        description: Sequences assembled from uncultivated virus genome (DNA/RNA).
      marker:
        description: Sequences from targeted region of DNA.
  CoordinateSystemEnum:
    description: Which coordinate space a SequenceFeature's start/end are measured in.
    permissible_values:
      contig:
        description: start/end are nucleotide positions on the referenced Contig.
      protein:
        description: start/end are amino-acid positions within the parent feature's translated sequence,
          not nucleotide positions on any contig.
  EndpointStatusEnum:
    description: Relationship of the true endpoint to the reported position.
    permissible_values:
      exact:
        description: Exact coordinate.
      before:
        description: Endpoint is before the reported coordinate, possibly outside the presented sequence.
      after:
        description: Endpoint is after the reported coordinate, possibly outside the presented sequence.
  LocationOperatorEnum:
    description: Relationship between ordered location parts.
    permissible_values:
      single:
        description: One interval.
      join:
        description: Parts are joined end to end.
      order:
        description: Parts have known order without asserting a joined sequence.
  MethodEnum:
    description: Annotation method or reference database that produced an evidence hit.
    permissible_values:
      pfam:
        description: Pfam protein families, https://www.ebi.ac.uk/interpro/entry/pfam/
      cog:
        description: Clusters of Orthologous Genes, https://www.ncbi.nlm.nih.gov/research/cog/
      tigrfam:
        description: TIGRFAMs protein families, https://www.ncbi.nlm.nih.gov/genome/annotation_prok/tigrfams/
      smart:
        description: SMART protein domains, https://smart.embl.de/
      supfam:
        description: SUPERFAMILY structural domain assignments, https://supfam.org/
      cath_funfam:
        description: CATH functional families (FunFams), https://www.cathdb.info/
      ko_ec:
        description: KEGG Orthology assignments and the EC numbers that come with them, https://www.genome.jp/kegg/ko.html
      tmhmm:
        description: TMHMM transmembrane helix predictions.
      signalp:
        description: SignalP signal peptide predictions.
  ScoreTypeEnum:
    description: Kind of number in a feature's score column.
    permissible_values:
      bit_score:
        description: A score normalised so that scores from different searches compare, in bits.
      e_value:
        description: Expected number of hits at least this good by chance.
      p_value:
        description: Probability of a result at least this extreme by chance.
      score:
        description: A tool-specific score of no more specific kind.
  StrandEnum:
    description: GFF3 column-7 strand values.
    permissible_values:
      +:
        description: Plus/forward strand.
      '-':
        description: Minus/reverse strand.
      .:
        description: Not stranded (GFF3 default).
      '?':
        description: Strand is relevant but unknown (GFF3 allowance).
  TopologyEnum:
    description: Reference topology used by location validation and distance queries.
    permissible_values:
      linear:
        description: Linear reference with no origin wrap.
      circular:
        description: Circular reference whose final base is adjacent to base one.
