meta.csv¶
One row is one composite statement and what it says. The statement is a member set: one or more
rows of the single-statement tables (variants, diplotypes, pharm_variants, allele_function),
each picked by a table[column=value, …] member. What it says is a finding (a conclusion, a per-trait
direction, its negatives) or the per-locus facts (tier, age of action and its confidence, tags), or
both. A row with one member and only facts is how a single locus or a named allele gets its tier; a row
with two members and a conclusion is a combination, such as KL-VS heterozygous with an APOE ε4 diplotype.
sex and drug scope the whole row, so each is part of what makes it one statement. CPIC answers a
TPMT × NUDT15 phenotype pair once per thiopurine, so that pair carries an azathioprine row, a
mercaptopurine row and a thioguanine row. The row's drug says which drug the statement is about; a
member's drug= condition is a different job, picking the diplotype or pharm rows that carry a drug.
A person decides every cell, and the compiler decides only what each member matched. The member
text is kept verbatim through reverse, so a selector the author wrote over a tag set
(variants[flags=legacy_longevitymap]) stays a selector rather than becoming every row it matched. The compiler writes those rows beside it, so a consumer reads matches and never evaluates a
rule.
Facts live here and nowhere else. A tier is never repeated on the genotype rows of a locus, so no two copies of it can drift apart. Two rows can still state two values for one row they both reach; the more specific one wins, column by column (a concrete row key, then a locus, then more conditions, then fewer; a diplotype over the alleles it contains; a sex- or drug-scoped row over the same key without one, for that sex or drug). Where neither is more specific and they disagree, the column is withheld, which is the ε2/ε4 case: two allele rows meet at one diplotype, and a third row keyed on that diplotype settles it. Unstated is not different: a specific row that leaves a fact empty takes the general row's value.
The symptom when it is wrong. A member that matches nothing is almost always a value spelled other
than the table stores it: a diplotype pair is stored with the smaller haplotype first, a genotype with
its alleles sorted. A per-trait row on a bare locus whose genotype rows disagree on effect_allele has
its direction withheld rather than guessed. A module carrying only this file is refused: it names rows,
and there are none to name.
Identity¶
| Row model | MetaRow (just_dna_format.meta) |
| Becomes | meta.parquet, meta_resolved.parquet |
| Authored or derived | authored — a person writes it (a drafter may append rows) |
| Draftable | yes — draft can append rows |
| Drafted by | no drafting provider targets this table — draft writes no row of it |
| Natural key | members_key, trait_efo_id, sex, drug |
| Fact signature | no |
| In the attestation binding | yes — manifest.inputs[] |
| Requires at least one of | conclusion or direction or negatives or tier or age_of_action or age_of_action_confidence or flags |
Columns¶
| Column | Type | Required | Values | Meaning |
|---|---|---|---|---|
members |
str |
required | The composite statement: one or more members joined by &, each table[column=value, …] over variants, diplotypes, pharm_variants or allele_function. Conditions are AND-ed; on a list column such as flags, = means contains. Inside a combination a member is existential (any row it matches). A value may not contain [, ], , or =. |
|
trait_efo_id |
str | None |
optional | EFO/MONDO/OBA/HP trait the row's judgement is about. Part of the key. | |
trait_role |
str | None |
optional | one of: mediator |
How the member reaches the trait: empty means the trait is an effect, mediator marks it as the path to another (LDL cholesterol on the way to CAD). Needs trait_efo_id. |
direction |
str | None |
optional | one of: contested, neutral, protective, risk, unknown |
The curator's judgement on the trait, the shared direction vocabulary. Every member of a row with a direction must fix an allele, so the judgement says which allele it is about. |
conclusion |
str | None |
optional | The finding. On a row with two or more members it replaces the findings of the rows the members match (a matching combination replaces the single-locus findings it names). | |
negatives |
str | None |
optional | The adverse counterpart to conclusion, as on variants.csv. |
|
tier |
str | None |
optional | Evidence tier, on the scale module_spec.yaml names once as tier_scale (refused without one). Open text: the scale is the module's, and values are not checked against it. |
|
age_of_action |
str | None |
optional | When in life the effect acts, in the module's own terms (e.g. MIDLIFE, LATE). | |
age_of_action_confidence |
str | None |
optional | How directly age_of_action is supported, in the module's own terms. |
|
flags |
list[str] | None |
optional | Open, multi-valued tag list (CSV: comma/semicolon/pipe-separated), as on variants.csv, so every kind of member can carry tags (e.g. ap:weak, hallmark:…). |
|
pmid |
str | None |
optional | PubMed id this row's claim is cited to, when the claim is finer than studies.csv's key (the RM47 pattern). Free-form like StudyRow.pmid. |
|
doi |
str | None |
optional | Digital Object Identifier of the work THIS row cites, kept verbatim (bare or as a doi.org URL). Optional beside a PubMed id; mandatory when pmid is NONE, the sentinel for a work PubMed does not index (a preprint, a book, a dataset), RM336. Same rule as StudyRow.doi. |
|
sex |
str | None |
optional | one of: female, male |
Scopes the whole row to one sex (male|female), matched by the consumer against karyotype. Part of the key; a row with sex outranks the same key without it, for that sex. |
drug |
str | None |
optional | Drug the row's statement is about, e.g. mercaptopurine; free text, as on diplotypes.csv and pharm_variants.csv. Scopes the whole row, so it is part of the key: one member set states one finding per drug, and a row with drug outranks the same key without it, for that drug. Not a member condition: diplotypes[drug=…] selects diplotype rows carrying that drug. |
Generated from the row model at build time — reference.authoring_reference(), the same answer describe_table gives an authoring tool. Nothing on this page is hand-kept.