Description
Deduplicate requiredKeys, count those present in sourceKeys, and count those present in both sourceKeys and verifiedKeys.
Metadata obligations and relations apply to a declared record scope. Field presence, source coverage, cardinality, and value correctness are independent properties.
Deduplicate requiredKeys, count those present in sourceKeys, and count those present in both sourceKeys and verifiedKeys.
When to use this tool
Use Metadata Source Coverage Share when you need a narrow metadata consistency or coverage check.
How to use the tool and how it works
- Enter requiredKeys, sourceKeys, verifiedKeys. Keep parallel arrays aligned. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read required, covered, verifiedCovered, share, defined. Inspect defined before interpreting the associated values.
Deduplicate requiredKeys, count those present in sourceKeys, and count those present in both sourceKeys and verifiedKeys. Divide verifiedCovered by a positive required count, otherwise return zero and defined false.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| requiredKeys | Required Keys | Required. Array of text; maximum UTF-16 length 8192; maximum items 256. |
| sourceKeys | Source Keys | Required. Array of text; maximum UTF-16 length 8192; maximum items 256. |
| verifiedKeys | Verified Keys | Required. Array of text; maximum UTF-16 length 8192; maximum items 256. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| required | Required | Required. Safe integer. |
| covered | Covered | Required. Safe integer. |
| verifiedCovered | Verified Covered | Required. Safe integer. |
| share | Dimensionless fraction under the stated denominator policy. | Required. Finite number. |
| defined | Whether the accompanying fraction has an available nonzero denominator. | Required. Boolean. |
{
"input": {
"requiredKeys": [
"a",
"b"
],
"sourceKeys": [
"a",
"b"
],
"verifiedKeys": [
"a"
]
},
"output": {
"required": 2,
"covered": 2,
"verifiedCovered": 1,
"share": 0.5,
"defined": true
}
} Limitations and assumptions
- Extra keys are ignored; source coverage and verification are supplied metadata, not a factual validation of field values.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
Alternative or Complementary methods
Apply the complete metadata profile and inspect field values and provenance before accepting a record.
References
Similar or alternative tools
- Metadata Obligation Missing Count
Select requiredFields absent from presentFields, deduplicate in first-occurrence order, and return missingFields and missingCount.
- Metadata Field Obligation Flag
Set obligationApplies when both inScope and required are true; missingRequired additionally requires present false.